Questions tagged [categories]

Every Post in WordPress is filed under one or more Categories. Categories allow the classification of your Posts into groups and subgroups, thereby aiding viewers in the navigation and use of your site.

Filter by
Sorted by
Tagged with
0
votes
0answers
20 views

How to set the same base url for two different taxonomies?

I have created two custom taxonomies. function themename_custom_taxonomies() { // Coaching Method $nieruchomosc = array( 'name' => _x( 'Nieruchomość', 'taxonomy general name' ), ...
0
votes
0answers
21 views

How to redefine the sorting of product categories by menu_order?

With the help of elementor and jetengine from crocoblock, I display product categories. These categories are sorted by the date they were added, but I would like them to be displayed in the order in ...
0
votes
0answers
18 views

How to use the Term Object from a custom select field in a query

I have a WordPress site in which I want to show 2 recent posts from a specific category. I want to use custom fields (via ACF in this case) to allow the site admin to choose/change the category ...
0
votes
0answers
72 views

How to make product image inherit from category image

I'm planning on importing large amount of products and automatically assign them to certain product categories(in woocommerce). I have 5 different categories and want for each product in each of those ...
0
votes
0answers
5 views

can i create an order form that is a seperate page and different catgeory of our existing on line store in woo commerce

I am relatively new to word press. Just navigating the learning curve. The page that i am working on is for a church that has an online store and they use woo commerce. i am trying to create a ...
0
votes
0answers
63 views

Get ACF Sub-Category image from loop

I'm using ACF to assign a category image to sub categories. Parent category-(contributors) > Sub categories-(contributor name). All my posts have multiple category and sub categories selected but I'...
0
votes
0answers
41 views

Sorry, no posts matched your criteria for only one of my blog pages

I have three categories on my website, each showing categorized posts (News, Blog, and Cases). I just added a new entry to the "cases" category, and now the entire page shows me "sorry, ...
0
votes
0answers
10 views

Need to print category and subcategory of current post item (Custom post type)

I have a custom post type called products and that have category and subcategory (locations) like Delhi, India Karnataka, India Sharjah, UAE Above are the categories and subcategories(child). Here ...
0
votes
1answer
447 views

wp_dropdown_categories and custom taxonomy + custom post type

I have created custom post type called "case study"(with slug case-study), with support of custom taxonomy which is called "theme". What i am trying to achieve? Simple dropdown, ...
0
votes
1answer
14 views

If x comments in a post move post to category y

If a post has 0 comments do nothing. If a post has 1 comment move the post to category 1. If a post has 2 comments move the post to cayegory 2. If a post has 3 comments or more move to category x.
0
votes
0answers
22 views

How to add categories to posts on specific future dates and time?

How can I add in admin page a functionality for each post to be able to choose for each post separately a specific future date and time (based on a date and time format settings configured in ...
1
vote
0answers
15 views

Scheduling update post daily

I have created a function to change the post category to archive after expiry date. And it will update every time when I save a post. But the question is that how can I schedule an update for posts ...
1
vote
1answer
29 views

List categories with posts

I know I can use wp_list_categories() to list categories, but how can I achieve to list also the posts under the respective categories, below an example what I want to achieve: category1 -- post ...
0
votes
1answer
66 views

Hide category name but show posts

I’m looking for a way to hide a specific category title (not all but just one specific category title) from being displayed on the home page, archives, and search results but still show the posts ...
0
votes
1answer
154 views

List all categories and count number of posts within based on custom date

I used this solution to count number of posts for each category (list). The counting is based on date post event (only from today's date). I got nothing var_dump show result of new WP_Query . but $...
0
votes
0answers
22 views

Show the tag if the custom field is set to "Yes"

Using the following code and shorcode, I display 10 tags in the basement of the site: function getTagListfoot($classes = '') { global $post; wp_tag_cloud( array( 'taxonomy' => 'tags_type', '...
0
votes
0answers
53 views

Data is lost after ajax call on Second filter (by date)

I have two filters. First one is the filter by post category, it works well. The second category filter is post by date (period = week, 2nd week) and work only on first click for this filter. Edit: I ...
0
votes
1answer
26 views

How to display custom taxonomy term specific post?

For example i have created a custom taxonomy news_type for custom post type news, if i add terms sports,games,politics to custom taxonomy so i want to display all post of politics taxonomy in a page,...
0
votes
0answers
24 views

how to loop through a specified array of categories

I need to create a template that lists all posts in a single category, then runs a secondary loop of categories specified in an array. For example: Page lists all posts "Award Winners". ...
1
vote
1answer
26 views

How to exclude category ID from Looper in Wordpress

I'm trying to exclude 2 (and potentially more) ID's from my loop, that displays all categories that have posts. The category ID's i'm currently trying to exclude are 1 and 19. I'm very new to PHP but ...
0
votes
1answer
28 views

Running script based on Category

I have a child theme with function.php where I am running a script in the header but now I want to tweak it to run only on posts listed under one category and avoid on homepage or other categories. ...
1
vote
1answer
37 views

Retrieving category's color with get_term_meta

I followed this tutorial to add colors to categories. However I can't make it work, when I try to use it in my loop nothing happens, I tried multiple versions but none was right. This is what I tried: ...
0
votes
0answers
16 views

How can I create a 'sub-blog' which has its own sidebar on individual posts?

I've created a WordPress site with a blog which has several categories of posts. One category, 'News', is a special one, and should display separately ('News' posts will only ever be tagged as 'News' ...
0
votes
1answer
17 views

Wordpress default post categories meta box widget

I have a plugin that automatically selects the categories in the wordpress post editor, sadly after installing the Rank Math - SEO plugin the default metabox of the post editor has changed and the ...
0
votes
0answers
9 views

Automatically assign taxonomy to all my subcategories

Right now I have this Category 1 > Category 2 I have a list of 300 subcategories that I need to assign to all my Category 2. Is there a way to do that?
1
vote
0answers
37 views

New Categories Not Shown In the Post Edit Page

I have a problem with setting up new categories for my new posts. When I publish my second article on the blog, I have created e new category. But when I posted it, the actual category is not showing ...
0
votes
0answers
21 views

How to display category list with category featured image

I am using Category Featured Image Plugin : https://wordpress.org/plugins/category-featured-image/ which sets a featured image for post by a category. The reason behind using this plugin is, it adds ...
0
votes
0answers
9 views

How to List Categories and Child categories by current logged in Author

I have created a site where all members are authors and is like a task managements system. Category -> Clients Child Category - > Brands So when a user/author is logged in i want he to see ...
1
vote
1answer
92 views

What's the Simplest Way to Override/Rewrite the %category% Permalink Structure Tag?

See: https://wordpress.org/support/article/using-permalinks/ By default, when someone sets their permalink structure to: /%category%/%postname%/ Post URLs appear like so: https://example.com/**abc**/...
0
votes
0answers
9 views

Categories to display 3 in a row instead of 2 and when clicked on should display only the Subcategories

Please I need help, I want to display my categories 3 in a row on mobile view and 5 or 6 in a row on computer view, and when clicked on should display on the respective subcategories without any post ...
0
votes
1answer
38 views

How to hide description on categories and tags?

Does anybody know how I can hide the descriptions from view for the categories and tags for my website? I have searched for a while but can't find any solutions. I would like it so that when they are ...
0
votes
0answers
22 views

affixing a parent category when importing xml into woocommerce

I configure import according to this manual.Categories are imported without hierarchy, all at the same level. What needs to be corrected in the code so that the hierarchy is taken into account when ...
0
votes
2answers
299 views

admin panel - How to remove "delete" button from category editing page

i want to disable, hide or remove delete buttons from category page I tried editing functions.php with no luck: add_action('admin_head', 'hide_category_buttons'); function hide_category_buttons() { ...
0
votes
0answers
10 views

Category Header

Do you know how I can edit the header in category pages? I want to change the color and the font. Thank you!
1
vote
0answers
12 views

Add a specific part of current category page url to shortcode

I have the following URL: website.com/category/xyz, where xyz can be hundreds of different words. I use a table plugin for displaying my content all throughout the website, and I want it to filter me ...
0
votes
0answers
37 views

Taxonomy custom check box meta field not getting saved

I am trying to add a simple checkbox to the category page but it not getting saved for some reason. Please help to fix the code below. Basically, I registered a meta then created check box. CheckBox ...
0
votes
0answers
12 views

How to match Category slug of one CPT with Second CPT?

I need to solve the problem which needs to be solve. Problem is I need to match post category / categories of one CPT with second CPT. if both are same then I want to display second CPT Posts in First ...
0
votes
0answers
15 views

Can WordPress term menu orders be changed?

WordPress Category Panel WordPress's default category page seen above. WooCommerce Category Panel (product_cat) category page for WooCommerce seen above. As can be seen in the picture below, there is ...
0
votes
1answer
17 views

Featured Category or Special Category in WordPress

Is there a way to make a category that will show in all categories in WordPress? For example, categories on my website are: Cat A Cat B Cat B1 Cat B2 Cat B3 I want a post tagged in Category A to be ...
1
vote
0answers
46 views

How do I hide or remove 'Category' from wordpress breadcrumbs

I'm building an ecommerce product page for a single product and am interested in including breadcrumbs. Since I only have a single product, how might I remove or hide the "Category" (...
0
votes
0answers
25 views

Subcategories randomly not working after page/post/category edit in wordpress. Fix: saving permalinks twice

We run a custom WP theme with some plugins including Yoast SEO premium and WPML. We also run a version without WPML. In the version WITH WPML subcategories (quite randomly) give back a 404. This seems ...
1
vote
0answers
92 views

Filter Categories in meta box for CPTs

Working with a custom post type in Wordpress, I would like to use the categories. So I added the categories to the cpt. No problems here. But, when adding or editing cpt items, I would like to filter ...
0
votes
1answer
33 views

How to get immediate children of a 'term' parent id through 'get_terms'?

I have a category orientation as: Series (ID: 15) (root category) Under 'Series', the following sub-categories are present: Series A (Contains 0 posts) Series B (Contains 1 post) Series C (Contains 0 ...
0
votes
0answers
9 views

Preventing specific portfolio categories from appearing on a Wordpress page

Im trying to prevent specific portfolio categories from appearing on a regular Wordpress page. I would be grateful for some advice about how to do this. Many thanks
0
votes
1answer
43 views

How to loop custom post_type from (a) specific category(ies)?

I'm using this code which works really fine to list quite everything I need as Featured image and title, from my custom posts "portfolio". <?php $args = array( 'posts_per_page' ...
1
vote
0answers
25 views

Multiple level category drop-down from the WordPress dashboard

Working with thousands of Categories in WordPress; parent categories, child categories, grand child categories. It is cumbersome trying to scroll through to select the desired category. It is either ...
1
vote
1answer
30 views

How to create button to direct to certain category

I am creating blog website for my client. I want to create couple of buttons and put them in the page. When clicking theese buttons user gotta be directed to certain categories. Thank you in advance
1
vote
1answer
34 views

How do I create a way for users to assign categories to a post from the frontend of the website?

Im looking for to add categories from a frontend post. I found a thread about this topic How do I create a way for users to assign categories to a post from the frontend? almost 9 years ago. There was ...
1
vote
2answers
62 views

Different templates for different category tags

Is there any method to create different template in a theme for different category tags search? For example, I have category 'blog' and category 'glossary' - there is no any similar tag for both ...
1
vote
0answers
14 views

Pagination not visible on woocommerce's category page

I am not able to display pagination on the category page on woocommerce, I have 18 products in a category but when I customise the rows and columns, it shows only a certain amount of products. I want ...

1
3 4
5
6 7
94