Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #58853, comment 5


Ignore:
Timestamp:
08/01/2023 06:06:44 PM (16 months ago)
Author:
flixos90
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #58853, comment 5

    initial v1  
    1 @joemcgill In your example, I think this wouldn't be a problem actually, since blocks (including dynamic blocks) are still parsed as part of `the_content` filter, so the shortcode in a block would have the same implications as a shortcode that is directly within the post content. So I don't think this would need to be specifically considered, it would be fixed by doing the same as I outlined in [comment:3 my above comment] for shortcodes in general.
     1@joemcgill In your example, I think this wouldn't be a separate problem actually, since blocks (including dynamic blocks) are still parsed as part of `the_content` filter, so the shortcode in a block would have the same implications as a shortcode that is directly within the post content. So I don't think this would need to be specifically considered, it would be fixed by doing the same as I outlined in [comment:3 my above comment] for shortcodes in general. Basically it is currently wrong as well, because the `do_shortcode` context is not among the contexts checked for around the early return if `doing_filter( 'the_content' )`.
     2
     3We can definitely add a test for it to make sure it's also covered.