[wp-trac] [WordPress Trac] #55522: Misleading method names plugin_dir_path and plugin_dir_url
WordPress Trac
noreply at wordpress.org
Mon Apr 4 17:09:48 UTC 2022
#55522: Misleading method names plugin_dir_path and plugin_dir_url
------------------------------+------------------------------
Reporter: subrataemfluence | Owner: (none)
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Plugins | Version: 5.9.2
Severity: normal | Resolution:
Keywords: has-patch | Focuses: accessibility
------------------------------+------------------------------
Comment (by joyously):
What is the problem you are trying to solve?
I think you can't make these changes or you will break some code.
The change for using `WP_CONTENT_DIR . '/plugins' ` is bad, since the
plugins folder could have been changed to something else using `define(
'WP_PLUGIN_DIR', 'somethingelse' );` unrelated to `WP_CONTENT_DIR` or
`/plugins'.
The change for `plugin_dir_url` makes the same call either way, which is
the default for those parameters, so why change it?
--
Ticket URL: <https://core.trac.wordpress.org/ticket/55522#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list