[wp-trac] [WordPress Trac] #35243: Extending the text widget to also allow visual mode

WordPress Trac noreply at wordpress.org
Thu Mar 16 16:42:30 UTC 2017


#35243: Extending the text widget to also allow visual mode
-------------------------+--------------------------------
 Reporter:  paaljoachim  |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  4.8
Component:  Widgets      |     Version:
 Severity:  normal       |  Resolution:
 Keywords:  needs-patch  |     Focuses:  ui, accessibility
-------------------------+--------------------------------

Comment (by westonruter):

 Replying to [comment:38 joyously]:
 > And I don't understand why it's so difficult to add a call to filter the
 widget with `do_shortcode` in core since shortcodes are a core thing. I'm
 not saying the output of a shortcode should be visible in your new Visual
 mode, just that shortcodes should work in text widgets because they work
 in content.

 The main challenge I see with shortcodes in the text widget is that
 certain shortcodes presume that they are being rendered in the context of
 `the_content` for a given post. Since a widget instance is not a post
 (yet, but #35669) these shortcodes could behave unexpectedly, such as if
 they are trying to obtain all of the attachments for the current post (as
 `gallery` does) or aggregating postmeta for display. There would need to
 be restrictions on which shortcodes would be allowed, or at least
 shortcodes would need to be educated on this new context.

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


More information about the wp-trac mailing list