Opened 17 years ago
Closed 16 years ago
#10888 closed enhancement (worksforme)
wp_head() arguments
| Reported by: | prometh | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Template | Version: | 2.8.4 |
| Severity: | normal | Keywords: | 2nd-opinion |
| Cc: | Focuses: |
Description
It'd be great if we could organize our <head> more. We could do this by separating things with wp_head() with 1 argument that would refer to a filter.
wp_head('link');
wp_head('meta');
wp_head('script');
with wp_head() echo'ing all. This would increase backwards compatibility.
Adding to the wp_head filters could work this:
add_action('wp_head_link', 'functionName');
add_action('wp_head_meta', 'functionName');
add_action('wp_head_script', 'functionName');
with add_action('wp_head', functionName); still working as it currently does.
Change History (2)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
I don't see a lot of people using this.
You could just add
do_action('wp_head_script');to your theme, if that's what you need.