Opened 3 years ago
Last modified 4 months ago
#13592 new enhancement
script_loader_src and style_loader_tag filters
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | Future Release |
| Component: | General | Version: | |
| Severity: | normal | Keywords: | has-patch needs-testing |
| Cc: | quietnic, tollmanz@…, td@…, retlehs |
Description
i'm trying to build a scripts and styles minifier.
( i don't like the way wp-minify does it ... )
thanks to the style_loader_tag filters, i'm pretty proud of my work for stylesheets.
but why don't we have a script_loader_tag ?
something like this in class.wp-scripts.php :
$src .= apply_filters( 'script_loader_tag', "<script type='text/javascript' src='$src'></script>\n", $handle );
ok i'll try to submit a real patch.
Attachments (1)
Change History (11)
- Keywords needs-patch added
- Milestone changed from Awaiting Review to Future Release
- Cc quietnic added
- Keywords needs-testing added
## not directly related to the ticket, but not sure where else to post this - remove if inappropriate ##
My apologies to the users Quiet and Nic (if they exist) who were inadvertently Cc'd to this ticket. It seems Trac, as with WP.org, has problems with names containing spaces.
After reading a number of WP.org support threads registering a new user seems to be the only option, so here I am, on a new user. Sorry for the mess.
comment:10
retlehs — 4 months ago
- Cc retlehs added

Add script_loader_tag filter to match style_loader_tag.