[wp-trac] [WordPress Trac] #47100: Use WPINC constant in script-loader.php, load-scripts.php, and load-styles.php instead of hardcoded wp-includes directory name
WordPress Trac
noreply at wordpress.org
Mon Jul 8 01:56:24 UTC 2019
#47100: Use WPINC constant in script-loader.php, load-scripts.php, and load-
styles.php instead of hardcoded wp-includes directory name
-----------------------------+----------------------
Reporter: mwarnermindedge | Owner: (none)
Type: enhancement | Status: closed
Priority: normal | Milestone:
Component: Script Loader | Version: 5.1.1
Severity: normal | Resolution: invalid
Keywords: | Focuses:
-----------------------------+----------------------
Comment (by Ryan_B):
Replying to [comment:6 SergeyBiryukov]:
> Replying to [comment:4 Ryan_B]:
> > Third, anyone using one of the loaders would need to define WPINC in
their script before calling the loader. Or better yet, allow wp-config to
be completly stand alone and not fully load WordPress. That would be a
simple as moving `require_once( ABSPATH . 'wp-settings.php' );` out of wp-
config.php and into wp-load.php after the require_once statement for wp-
config.php then the script loaders could bring in wp-config.php to get teh
WPINC constant from there if its defined.
>
> Just wanted to note that this doesn't seem as straightforward in terms
of backward compatibility. It would require every WordPress user to
perform the change to `wp-config.php`, which does not seem feasible, since
many of them may not know where it's located or how to edit it.
I am confused by what you mean by this. What is it that everyone would
have to change? If you are referring to everyone having to include WPINC
in wp-config.php no they wouldn't. Core could still have the default path
defined if it is not already defined, just like it does for wp-content.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/47100#comment:7>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list