WP Post Loop widget – excluding category posts
-
Hello to all,
I’m not an expert, so my question may be silly and I apologize in advance.
I use SiteOrigin North theme with SiteOrigin page builder on almost all pages.
My blog page is named “articles” but is not assigned as “blog page, it’s a page like any other one.
I use the default WP post loop widget in the Site Origine page builder to get my posts on the articles page.
At the moment, all articles are included in the widget loop.
I would like to exclude 3 categories.
I guess I have to write an additional query in the widget to exclude those categories but I am unable to do it.
Could someone give me the correct syntax of the query ? (with category slugs as it seems there is no more category ID numbers)
Thank you very much in advance!
The page I need help with: [log in to see the link]
-
Review this codex guide for some info:
https://codex.wordpress.org/The_Loop#Exclude_Posts_From_Some_CategoryAlso, review this plugin and see if it can do what you intend:
https://wordpress.org/plugins/ultimate-category-excluder/Hi and thank you for your answer. Unfortunately this doesn’t help.
The first link to the codex indicates how to excude categories from a post page template. I have no post page. My post page named “articles” is an ordinary page that I have build with SiteOrigin Page Editor using widgets.
The second link is a plugin which doesn’t allow excluding categories for specific pages, only the front page, the feeds, the archives and the search templates.
For clarification, I have made an article on my blog with two screenshots.
The first one shows the architecture of my page with Site Origin Page Builder and the page loop widget.
The second one show the location inside the built-in post loop widget where I think I can write an exclude query. I just don’t know how to write it.Here is the link to this article:
http://www.fcknfrdm.com/2018/01/10/presentation/query-excluding-categories-in-posts-loop-built-in-widget/Hope this helps.
Thank you!
Found it!
I thought the post loop widget I used was built in WP but it’s a theme built-in widget, so I found the answer in the theme support forum.
Thank you anyway for your answer.
You are welcome 🙂
- The topic ‘WP Post Loop widget – excluding category posts’ is closed to new replies.