[英]Wordpress : list posts from category with AJAX and call plugin on it
[英]List Category posts Wordpress plugin not working
我是WordPress的新手,并尝试使用List Category WordPress插件在首页上按类别显示帖子。 我已经安装并激活了该插件,并按照其文档中的说明进行了安装( https://github.com/picandocodigo/List-Category-Posts/blob/master/readme.txt ),将以下代码添加到index.php
文件中,按类别名称获取帖子:
[catlist name="bike-rides"]
(两边都被`包围,stackoverflow正在格式化它)
添加此代码后,此文本将显示在网站上,而不是显示该类别的帖子。
谁能帮忙吗? 我可能正在做一些非常愚蠢的事情,所以请忍受我。
嗨,你能试试看吗
<?php echo do_shortcode( '[catlist name="bike-rides"]' ); ?>
我们应该使用do_shortcode
函数在wordpress中的php文件中插入简码,请尝试一下
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.