[wp-trac] [WordPress Trac] #24813: wp_add_inline_style behaviour changes with SCRIPT_DEBUG

WordPress Trac noreply at wordpress.org
Tue Oct 8 18:30:58 UTC 2013


#24813: wp_add_inline_style behaviour changes with SCRIPT_DEBUG
------------------------------+-----------------------------
 Reporter:  stephenharris     |       Owner:  SergeyBiryukov
     Type:  defect (bug)      |      Status:  closed
 Priority:  normal            |   Milestone:  3.7
Component:  General           |     Version:  3.3
 Severity:  normal            |  Resolution:  fixed
 Keywords:  has-patch commit  |
------------------------------+-----------------------------

Comment (by georgestephanis):

 I'm not sure if this is really the best resolution here.  It's breaking
 things that had worked previously.

 The documentation on wp_add_inline_style
 [http://codex.wordpress.org/Function_Reference/wp_add_inline_style in the
 codex] and [https://wpcom.trac.automattic.com/browser/trunk/wp-
 includes/functions.wp-styles.php#L48 in the phpdoc] states explicitly to
 pass the CSS in as the second parameter -- nowhere is it indicating that
 it should include tags, and the example in the Codex explicitly doesn't
 include the tags.

 If we're changing how the function is used, okay I guess, but can we add
 something to wp_add_inline_style that will wrap the string in <style> tags
 there if it's just clean CSS, for backcompat?

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


More information about the wp-trac mailing list