删除WordPress中的Post a标签

我对Wordpress创建代码的方式有疑问。
【删除WordPress中的Post a标签】我的帖子应该包装在div中, 但Wordpress会创建一些额外的< a> 包装, 但我不知道如何消除它们。
有人有主意吗?
我的代码如下。

< article @php(post_class(mainpagepost))> < div class="entry-center"> < header class="entry-header"> < div class="entry-header-subinfo"> @php(the_category()) | @php(the_date()) < /div> < h2 class="entry-title"> < a href="http://www.srcmini.com/{{ get_permalink() }}"> {{ get_the_title() }}< /a> < /h2> < /header> < div class="entry-summary"> @php(the_excerpt()) < /div> < button type="button" class="btn btn-default"> < a href="http://www.srcmini.com/{{ get_permalink() }}"> READ MORE< /button> < /div> @php(the_post_thumbnail(entry-image)) < /article>

它将这些代码行添加到它们之上。
< /a> < /div> < a href="http://www.srcmini.com//localhost:3000/Git/VoiceBooking%20Blog/wordpress/index.php/2017/12/13/welcome-to-this-blog/">

#1代码中的这一部分表示完整文章的链接:
< a href="http://www.srcmini.com/{{ get_permalink() }}">

(以及每个结束符< /a> 的标记。)
因此, 如果删除这些链接, 则可以删除这些链接。但是, 请注意, 它们导致了完整的帖子-你上面发布的代码仅会显示端口的一部分(摘录), 因此你需要某种方式让用户看到完整的帖子。在问题代码中完成代码的方式确实非常普遍, 这是人们习惯的。
补充:实际上, 在这一行中, 你的代码中缺少< /a> 结束标记:
< button type="button" class="btn btn-default"> < a href="http://www.srcmini.com/{{ get_permalink() }}"> READ MORE< /button>

那应该是
< button type="button" class="btn btn-default"> < a href="http://www.srcmini.com/{{ get_permalink() }}"> READ MORE< /a> < /button>

当Wordpress或浏览器尝试更正该不完整的链接时, 这可能会在HTML输出中引起一些麻烦…

    推荐阅读