You can filter post_class
and change these class names:
add_filter( 'post_class', 'wpse_78237_post_class' );
function wpse_78237_post_class( $classes )
{
$out = array ();
foreach ( $classes as $class )
{
if ( 0 === strpos( $class, 'tag-' ) )
{
$out[] = substr( $class, 4 );
}
elseif ( 0 === strpos( $class, 'category-' ) )
{
$out[] = substr( $class, 9 );
}
else
{
$out[] = $class;
}
}
return array_unique( $out );
}
But be aware this could result in collisions with other class names, in body_class
for example. I would not do that.
Related Posts:
- Is There a Difference Between Taxonomies and Categories?
- Can’t custom taxonomies have same terms (slugs) as categories?
- How to display non-hierarchical taxonomy as terms with checkboxes?
- How do the ‘tag’ and ‘category’ (default) taxonomies do ‘save_post’ action?
- Checklist of selected categories
- Use tag interface for hierarchical taxonomy?
- Sort posts by tags in category pages
- How to search for categories and/or tags?
- Using URL parameters, list posts from category and custom taxonomy
- How to get the url to tag & category base set by the user?
- Filter categories using tags
- Sticky posts on home page, search, tag and archives without plugin
- Are Categories, Tags and Custom Taxonomies any different in regards to SEO?
- Create subdomains for tags and categories
- In the tag archive – display count of posts for each category they belong to
- Is it possible to disable certain user roles from creating tags?
- How to totally get rid of Category in my blog?
- Root level category, tag, author and archive pages to work
- Showing all the posts in one page?
- How can I make wp_list_categories output li with category-slug as class, for its children?
- Categories and Tags returning 404 on the sidebar when using ugly permalinks
- Is it possible to put tags and category information in the post as text?
- Script to duplicate categories as tags
- Remove Categories and Tags from Admin Dashboard
- Remove Archive Headline and Archive Intro Text fields on category and tag archive pages in WordPress Admin with Genesis framework
- display most popular tags of category?
- Can paginate_links() be customized for a specific category or tag?
- Any way to assign Post Categories and Tags to Links?
- Help with multiple dropdown tags search
- Hide tag and category boxes from the post editor
- Retrieve all posts within tag OR category?
- Categories: A Greenhorn Question on Strategy (Not Code)
- How to customize tag and category post listings to show introductory content?
- Warning: sizeof (): Parameter must be an array or an object that implements Countable, On products pages
- How can I duplicate categories and tags?
- How to run select query of post with category and tags for API?
- Making a tourism information website [closed]
- How get permalink for the current category or tag?
- Changing permalink from /postname/ to category/postname/
- Site search needs to find posts for category topic AND Tag or keyword thats not in the post
- Pagination is not working properly in Product Category/Tag pages
- How to display categories which contains particular tag?
- “Categories” for six authors [closed]
- How to “group” (categorize) the Pages together?
- Is There a Difference Between Taxonomies and Categories?
- Custom SQL Query: Get all posts with category id and a concated list of tags on each post
- Related Tags not in category
- scaleability of tags
- How to Remove a Title from All Category and Tags Page?
- How can i remove the posts category class names from body_class
- How do I add a tag slug to a category URL to filter posts?
- How can I display tags as categories?
- Show the amount of posts in a tag in a specific category has
- How to get an array with all categories and corresponding names?
- Echo text using is_tag
- Adding a H1 Tag to Post Tags automatically, but hide the tag? (Same for Category)
- Conditional category & tag statement
- Use blog as base for tags and categories
- Get categories list with category name in custom WP_List_Table class
- Include either name or slug in the include parameter using wp_list_categories?
- List all posts of certain category which share some tags
- How to store category and tags separatly on wordpress?
- How can I filter posts by tag on the fly
- Retrieve post tags from from main wp_query
- Advanced permalinks structure
- What is the best way to add an advanced / intermediate / beginner tag to a post
- display specific category when website loads
- Automatically adding tags and categories into Post Excerpt for searching
- How to add tags under categories
- Add Post Categories in Post Tags Field Programmatically
- Return all Tags and Categories in Separate List
- How to filter tags by category?
- Count how many posts have a specified tag AND category
- How to prevent tag “iframe” from being deleted from the heading description of rubric?
- Automatically create tags and merge with categories
- How to assign Categories and tags inside the TinyMCE Editor for each Image?
- Re-coding category-template.php to go to custom URL
- Balance Tags to the_content Words Length
- custom browse by
- Search by tag, category and author without plugin
- Limit Category/Tag Dropdown To blog_id in Multisite Install With Global Categories/Tags
- Categories and Tags Conflict after Woocommerce Installation
- How can I add metaboxs to Admin Bar?
- Split posts into 2 separate streams
- Tag Menu items based on their categories
- How to add an “All” category to the tag cloud?
- Exclude posts with certain tags in category archive
- Getting Post Tags From Certain Categories
- Different styles for categories – need to edit a plugin
- Unable to get all tags from specific categories
- Page Type with Category Link
- How to add an empty entry to masonry?
- Own Custom Tags/Category page ( posts)
- altering theme – content generated by PAGES not PORTFOLIO
- Tracking multiple tags or categories
- How to load jquery tag-it plugin into admin?
- Modify functions.php to add a term ‘uses-theme’ set to theme name on post save
- Query posts that have all the specified tags
- Moving Blog and Changing URL
- In my wordpress admin panel Suddenly The Category, tag and featured Image Option are not showing