<!-- wp:post-title {"isLink":true,"level":1,"className":"hclass"} /-->
When using the above in index.html/single.html, WordPress renders:
<h1 class="hclass"><a href="post-url">Post Title</a></h1>
But I want:
<h1><a class="hclass" href="post-url">Post Title</a></h1>
I have to create a Custom Quesry Block or some other methods are there to control the output rendering on a public Post?
<!-- wp:post-title {"isLink":true,"level":1,"className":"hclass"} /-->
When using the above in index.html/single.html, WordPress renders:
<h1 class="hclass"><a href="post-url">Post Title</a></h1>
But I want:
<h1><a class="hclass" href="post-url">Post Title</a></h1>
I have to create a Custom Quesry Block or some other methods are there to control the output rendering on a public Post?
Share Improve this question asked Mar 16 at 15:25 WordCentWordCent 1,8916 gold badges34 silver badges60 bronze badges1 Answer
Reset to default 1You can use render_block_core/post-title hook to change block output. To change output, use Wordpress html API or regex replacements.