#14157 closed enhancement (fixed)
wp-includes references should be wiped off
Reported by: | steak | Owned by: | wonderboymusic |
---|---|---|---|
Milestone: | 4.1 | Priority: | lowest |
Severity: | minor | Version: | |
Component: | Bootstrap/Load | Keywords: | has-patch |
Focuses: | Cc: |
Description
I think all references to wp-includes should be wiped off and use the WPINC WP constant. This may allow for a future renaming of the wp-includes folder if needed.
E.g in script-loader.php:
$scripts->add( 'jquery-ui-core', '/wp-includes/js/jquery/ui.core.js', array('jquery'), '1.7.1' );
To:
$scripts->add( 'jquery-ui-core', '/' . WPINC. '/js/jquery/ui.core.js', array('jquery'), '1.7.1' );
Attachments (3)
Change History (35)
#1
@
14 years ago
- Summary changed from wp-include references should be wiped off to wp-includes references should be wiped off
#2
@
14 years ago
- Milestone changed from Awaiting Review to Future Release
- Priority changed from normal to lowest
#4
@
14 years ago
- Cc wojtek.szkutnik@… added
- Keywords has-patch needs-testing dev-feedback added; needs-patch removed
#6
@
13 years ago
- Cc anantshri added
Hi This should be done.... if no one is working on it i can try creating a patch, as per my initail scan of the whole folder structure only 1-2 files can have some problem other then that all could be modified.
will start working if no objection is recieved.
#9
@
10 years ago
- Keywords needs-testing dev-feedback gsoc removed
- Milestone changed from Future Release to 4.0
#12
follow-up:
↓ 15
@
10 years ago
[28905] is using WPINC directly in a URL, versus a filesystem path. It should instead be using includes_url().
#17
@
10 years ago
14157-script-loader.diff uses includes_url( ..., 'relative' )
all over script-loader.php
#18
@
10 years ago
- Owner set to wonderboymusic
- Resolution set to fixed
- Status changed from new to closed
In 28911:
#20
@
10 years ago
- Resolution fixed deleted
- Status changed from closed to reopened
[28911] should be reverted. This is much slower, and the script loader has an internal implementation where it detects /wp-includes/ or /wp-admin/ at the start of a script and then switches it out with a base url. Some other checks specifically depends on wp-includes and wp-admin.
#26
@
10 years ago
Found a case in wp-admin/includes/ms.php
: https://core.trac.wordpress.org/browser/trunk/src/wp-admin/includes/ms.php#L810
var tb_pathToImage = "../../wp-includes/js/thickbox/loadingAnimation.gif";
Should be changed to:
var tb_pathToImage = '<?php echo includes_url( 'js/thickbox/loadingAnimation.gif' ); ?>';
Not sure if the relative
context as second argument is needed.
Patch attached. Although, I have a few questions:
wp-admin/includes/update-core.php - it is unclear to me, if the wp-includes references should stay or not
wp-admin/network.php and wp-includes/rewrite.php I need strong testing and feedback on these rewrites, can anyone confirm it works as expected?
wp-includes/js/thickbox/thickbox.js two references to wp-includes in a js file, how can these two be handled?