[wp-trac] [WordPress Trac] #60948: shortcodes that return with no value / text will break if shortcode is being used as an attribute value

WordPress Trac noreply at wordpress.org
Sat Apr 6 19:59:15 UTC 2024


#60948: shortcodes that return with no value / text will break if shortcode is
being used as an attribute value
--------------------------+------------------------------
 Reporter:  vpelss        |       Owner:  (none)
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Shortcodes    |     Version:  6.5
 Severity:  normal        |  Resolution:
 Keywords:                |     Focuses:
--------------------------+------------------------------

Comment (by vpelss):

 The test for

 {{{
  '' !==
 }}}

 is the issue I think.

 Surely there are valid cases when a shortcode should be allowed to return
 no text.

 When that occurs in a tag's attribute, the code can't cope.
 Thus:

 {{{
 value="title="Please"
 }}}

 in my example.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/60948#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list