Parent Category Posts Missing from Related Posts on Single Post Page

Posted in: Newspaper
Post count: 9

Hello,

I’m using the Newspaper theme and noticed that on a single post that belongs to a subcategory, the related posts section only shows posts from the same subcategory, but not from the parent category.

For example, if a post is in “Books > Fiction”, then related posts only show other posts in “Fiction” but not from the parent category “Books”.

Is there a way to include posts from both the subcategory and its parent category in the related posts?

I’ve tried overriding the single.php and using a custom function, but I’d prefer to use the theme’s native related posts system if possible.

Please guide me on how I can achieve this.

Thank you!

Post count: 35449

Hi,
This is how the options have been made to work, so using the option for Single – Related by category will display only articles from the same level, now if there is only one or 2 situations you can use the filter Single – Related from taxonomy and set the – https://i.imgur.com/ndkcbyc.png
Thank you!

Post count: 9

Hi, thanks for your response.

When reader visit on sub category “fiction” post, than show only in related posts related to “fiction” only. but i want to show all post under “books” category.

This is sub category “fiction” post url.
https://www.authorswiki.com/books/fiction/the-light-upon-eyes/

Screenshot – https://ibb.co/vvZwYmxL

Post count: 35449

Hi Rajender Singh,
I see that you are using standard templates and not cloud templates, but the mode that the block works is the same, the Related Articles will display only article s on the same level, so if you are in a subcategory, then will display only articles from that subcategory. If you want to change it you’ll need a developer that know how to change the code in wp-content/plugins/td-standard-pack/Newspaper/includes/shortcodes/td_block_related_posts.php file so it will work as you need.
Thank you for your understanding!

Viewing 4 posts - 1 through 4 (of 4 total)
The forum ‘Newspaper’ is closed to new topics and replies.