[wp-trac] [WordPress Trac] #19510: wp_print_styles() causing mid-page scripts/styles to bleed into admin

WordPress Trac wp-trac at lists.automattic.com
Mon Dec 12 06:28:20 UTC 2011


#19510: wp_print_styles() causing mid-page scripts/styles to bleed into admin
-------------------------------------+------------------
 Reporter:  AdamBackstrom            |       Owner:
     Type:  defect (bug)             |      Status:  new
 Priority:  normal                   |   Milestone:  3.3
Component:  Editor                   |     Version:  3.3
 Severity:  critical                 |  Resolution:
 Keywords:  dev-feedback regression  |
-------------------------------------+------------------

Comment (by azaozz):

 Replying to [comment:10 scribu]:
 > We really use wp_print_scripts() in two ways:
 >
 > a) to output all the styles enqueued so far, in which case the
 'wp_print_styles' hook makes sense without a parameter.
 >
 > b) as a wrapper for {{{$wp_styles->do_items( $handle )}}}, in which it
 doesn't make sense to fire the hook, even with a parameter, due to the way
 it's already used in the wild.

 Right. The same is true for both `wp_print_scripts()` and
 `wp_print_styles()`. It doesn't make sense to run the hooks when used as
 shortcuts to `$wp_styles->do_items()` and `$wp_scripts->do_items()`. Until
 3.3 this wasn't causing problems as these hooks didn't matter when run
 mid-page.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/19510#comment:12>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list