• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Load website from PhpStorm

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › General Discussion › Load website from PhpStorm

This topic is: not resolved

Tagged: PhpStorm IDE

  • This topic has 3 replies, 2 voices, and was last updated 8 years, 5 months ago by clintongallagher.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • July 31, 2017 at 10:31 am #209763
    clintongallagher
    Member

    I just installed Genesis into a new instance of a website opened as a Project in PhpStorm. Yes, I know I need to install child theme but something has been bothering me.

    When I try to load a website from the browser the website loads as expected but when I try to load the website from PhpStorm using the path wp-content > themes > genesis > index.php I get the following error:

    Fatal error: Uncaught Error: Call to undefined function genesis() in /srv/www/website-name/htdocs/wp-content/themes/genesis/index.php:15 Stack trace: #0 {main} thrown in /srv/www/website-name/htdocs/wp-content/themes/genesis/index.php on line 15

    If I tried to load index.php from Twenty Seventeen the error becomes:

    Fatal error: Uncaught Error: Call to undefined function get_header() in /srv/www/website-name/htdocs/wp-content/themes/twentyseventeen/index.php:17 Stack trace: #0 {main} thrown in /srv/www/website-name/htdocs/wp-content/themes/twentyseventeen/index.php on line 17

    Is this a PhpStorm configuration issue or do I misunderatand how to load a WordPress website from an IDE?

    July 31, 2017 at 2:28 pm #209777
    Victor Font
    Moderator

    You can only load a WordPress website from the main directory. wp_settings needs to be called to initialize WordPress. When you attempt to load a site from a theme directory you bypass all of the WordPress initialization functions.


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

    July 31, 2017 at 4:39 pm #209782
    clintongallagher
    Member

    Hello Victor,

    Okay then,loading wp_settings.php generates more errors:

    Notice: Use of undefined constant ABSPATH - assumed 'ABSPATH' in /srv/www/***/htdocs/wp-settings.php on line 19

    Warning: require(ABSPATHwp-includes/load.php): failed to open stream: No such file or directory in /srv/www/***/htdocs/wp-settings.php on line 19

    Fatal error: require(): Failed opening required 'ABSPATHwp-includes/load.php' (include_path='.:/usr/share/php') in /srv/www/***/htdocs/wp-settings.php on line 19

    Indeed, the only definition in wp_settings.php is define( 'WPINC', 'wp-includes' );
    and ABSPATH is not defined. Implies ABSPATH must be initialized elsewhere and something else would be loading wp_settings.php.

    July 31, 2017 at 4:45 pm #209783
    clintongallagher
    Member

    Wait a minute. Requesting htdocs > index.php loads the website. I've been trying to load from the wrong location. Got a reference to a doc that lists the filenames and the order each loads?

  • Author
    Posts
Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘General Discussion’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2026 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble