[wp-trac] [WordPress Trac] #33116: do_shortcode('<[shortcode]') doesn't work

WordPress Trac noreply at wordpress.org
Mon Jul 27 23:05:15 UTC 2015


#33116: do_shortcode('<[shortcode]') doesn't work
--------------------------+--------------------
 Reporter:  Kleor         |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  4.2.4
Component:  Shortcodes    |     Version:  4.2.3
 Severity:  minor         |  Resolution:
 Keywords:  has-patch     |     Focuses:
--------------------------+--------------------

Comment (by knutsp):

 Replying to [comment:9 miqrogroove]:

 > If we had an easy choice about whether or not to encourage plugins to
 use {{{<[sender email-address]>}}} style and run do_shortcode in email
 headers, I think the answer would be "no".  It's difficult to parse, even
 more difficult to secure in this version, and we can't allow it in many
 situations anymore.  Especially in a context that is not related to post
 content, shortcodes are not even needed.  One could more easily use
 str_replace and have an arbitrary template like {{{##sender-email##}}}.
 It would run faster, not be constrained by Shortcode filters, and give the
 plugin full control of the output.
 >
 > So when I say backward compatibility is a big concern, I mean it might
 be the only reason to fix this.

 Thank you. Great answer. Do you see problems with plugins having to revert
 to using `str_replace()` and arbitrary placeholder formats? I mean, not
 just just for backwards compatiblity, but forward looking?

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


More information about the wp-trac mailing list