admin管理员组文章数量:1122846
I am using a custom page template in the "twenty twenty-three" theme. I am using a shortcode block as part of the template. This results in the shortcode not running within "the_content", as that block is being called separately. I can run this specific shortcode inside the content area and in the footer (neither of which is where I want the shortcode's output to display) and it works fine. However, when I run it as a block in the page template, paragraph elements are being inserted that break the output.
I have tried applying the shortcode_unautop() function to the shortcode's output without success, and I have tried removing and then re-applying the wp_autop() filter as described in ... but none of it works because those seem to still need to be run within hooked areas like "the_content". Can anyone point me toward a method of disabling wp_autop on a shortcode block within a block-theme page template?
本文标签:
版权声明:本文标题:How can I remove the wp_autop filter from a shortcode block in a block theme page template (twenty twenty-three)? 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1736302342a1931498.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论