[wp-trac] [WordPress Trac] #37060: wp-load.php wrong paths
WordPress Trac
noreply at wordpress.org
Thu Jun 9 05:52:14 UTC 2016
#37060: wp-load.php wrong paths
--------------------------+------------------------------
Reporter: DuckDagobert | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 4.5.2
Severity: normal | Resolution:
Keywords: | Focuses: performance
--------------------------+------------------------------
Comment (by DuckDagobert):
So this is caused by plugins?
If yes, I will check the plugins
Thanks!
Replying to [comment:1 dd32]:
> Based on the filenames here, this looks like it could quite possibly be
caused by plugins using relative paths in their `include`s and `require`s.
> ie. `require './my-other-file.php';` and `require 'my-other-file.php';`
rather than `require __DIR__ . '/my-other-file.php';` WordPress uses the
latter in most places
>
> PHP will see a relative path like that and resolve it according to it's
`include_path` configuration, in most scenario's it should check the
script directory first, but in your case, due to some configuration, it
appears to be checking the current working directory first, rather than
relative to the file which is executing the include statement.
>
> There's not really anything WordPress can do here, it's mostly down to
PHP's internal behaviours.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/37060#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list