开发者

Hide posts in wordpress

I've created new entities that are similar to posts which are displayed via my custom pages. When I create this custom entity I also create new post and attach post ID to custom entity, so I can post comments to my custom entity.

I open page with my custom entity and comments are displayed too, and everything is great, exce开发者_Go百科pt that if in browser I type the permalink for this underlying post I created the wordpress will open the post page, which I don't want to be displayed at all. How can I hide post pages that I create? Notice, that these underlying posts can be of one single category.

Thanks


In single.php or equivalent, check the category of the post. If it is in your special category, don't display it.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜