[wp-trac] [WordPress Trac] #49941: Replace path building for include with direct filename

WordPress Trac noreply at wordpress.org
Sat Apr 18 06:38:37 UTC 2020


#49941: Replace path building for include with direct filename
----------------------------+-------------------------------
 Reporter:  flip101         |       Owner:  (none)
     Type:  enhancement     |      Status:  closed
 Priority:  normal          |   Milestone:
Component:  Administration  |     Version:
 Severity:  normal          |  Resolution:  wontfix
 Keywords:                  |     Focuses:  coding-standards
----------------------------+-------------------------------
Changes (by SergeyBiryukov):

 * status:  new => closed
 * resolution:   => wontfix
 * focuses:   => coding-standards
 * component:  General => Administration
 * milestone:  Awaiting Review =>


Comment:

 Hi there, welcome to WordPress Trac! Thanks for the ticket.

 Using `ABSPATH` is intentional here, see [25616] / #17092 and
 comment:1:ticket:37060 for more context.

 Switching to a relative path would make the code rely on PHP
 `include_path` configuration, which in some scenarios can lead to
 including a wrong file and causing obscure issues.

 Using a full path guards against that.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/49941#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list