If you are using the_category()
(so without passing parameters), the result will be something like:
<ul class="post-categories">
<li><a href="https://wordpress.stackexchange.com/questions/262546/cat1">Category 1</a><li>
<li><a href="http://wordpress.stackexchange.com/cat2">Category 2</a><li>
</ul>
So a css line like .post-categories li a {font-family:Myfont;}
should do it.
Reference: the_category()
calls get_the_category_list
, which does the actual output. This function ends with a filter, which you could use to assign further classes, even to individual links.
Related Posts:
- Edit the markup of categories list
- How to get data about category in category.php
- How to check category of of custom post type or not
- Set a them for all subset of category
- Show posts from all categories
- altering theme – content generated by PAGES not PORTFOLIO
- How to check if I’m on the last page of posts?
- How to get category and archive title?
- Display random categories on the front page (Finding and Editing Theme Functions)
- Check if current category has subcategories
- wp_nav_menu not appearing for a couple pages
- Posts in multiple Categories different single.php
- wp_update_nav_menu_item() to insert categories
- How to get the url to tag & category base set by the user?
- Multiple level category drop-down
- Loop with Dynamic Categories
- Listing all posts from current category on page
- is_archive() content being shown instead of is_category()
- How to highlight the current page in the nav menu?
- What type of page should i use? static page or category page? and what’s the difference? [closed]
- Duplicate Category and Page URL loads Category instead of the Page
- Add a specific category at a specific place to the menu that uses wp_list_pages
- Retrieve all posts within tag OR category?
- Viewing category pages without the word ‘category’ in URL
- Can’t load WP function into external function
- Categories vs. Page Site Organization
- New Theme creation
- How to make 2 tag feeds show up on 1 page?
- Different templates for different category tags
- Search in custom post type AND in pages with category
- Why category.php throw 404 in wordpress while calling paginate_links()?
- Give a page priority over a category that has the same name?
- Different banner for different section
- Putting a Category of posts under a Page
- How to place HTML tags in content from the_content()?
- How can you change the permalink for pages?
- Inside a loop, how to change CSS class based on category name?
- Should I use “Categories ” or “Pages” for a WordPress Static Site (A non blog site)?
- Category.php loads first before page.php?
- How to do some action weekly?
- Automatically redirect a page to a category that share the same slug
- How to create a subcategory to a PAGE on WP?
- Question on using custom structures for categories
- How to show 5 posts from specific category on related page?
- How do I get category and page ID’s?
- Getting the category title / description returns first matching post?
- How can I display tags as categories?
- Trying to create a Categorised Index (archive?) to use as my Home Page
- Allow user to select categories that will display in post loop
- How do I retrieve the category ID (ugly permalinks) in my sub-navigation menu?
- How to track a users last visited page?
- Category page returns 404 error
- Getting the Most Recent Posts from Multiple Categories
- Theme for subcategories
- Theme modification for custom category menus
- Show post categories
- Add description to categories menu in admin
- filter a loop base on specific category
- Problem with multiple loops in wordpress theme
- custom query for both category and pages using global $wpdb;
- How to differentiate the homepage structure from the category page structure in WordPress template?
- How to use category slug with a regular page
- How do I remove “Uncategorized” from my theme on my posts page?
- Products category search not working
- When I click for the redirect link it is showing the content of index.php instead of single_assignment_page.php
- How to prevent WordPress from redirecting single page to prefixed category archive with same name?
- Template category.php with page (no posts)
- In if…else condition, the else statement shows even if if statement is correct
- What plugin would make this happen? If is the theme
- Can’t display posts by filtering categories using isotope.js
- Showing the category hierarchy as clicked in WordPress, with image and desc
- Regarding Tags And Categories
- How to show some of category in wordpress
- Creating a theme just to deploy a single page
- displaying one category on one page
- WordPress Twenty-Fourteen: How to Remove Home Page Header Image from Other Pages
- Style a category page the same way as the homepage?
- Adding a category view to a page
- wp_editor some functionality not working on custom theme
- One-Page WordPress Template
- How to create multiple pages in a client theme?
- Jetpack Mobile Theme: when on smartphone on categories the theme suddenly changes to jetpack mobile theme even though it’s deactivated
- Paginations in Category Page Leads to Sample Pages
- If it is a top level category show children otherwise show sibling categories
- Include category name in page template
- How to get multiple loop in category.php, my scripts becomes madness
- Category base 404 – fix
- Category page with gallery for each post
- How get the 10 most viewed pages (not post)
- Custom built theme won’t filter categories
- Return selected categories only in custom page meta box?
- Need help with category page customization meeting certain condition
- Standard Way To Do Custom Work Within A Page?
- Show custom menu in category and its posts
- Duplicate homepage to show posts from 1 category
- WordPress 3.5 how to determine if user is on category listing or category edit screen?
- Display only one level subcategory in wordpress
- Get all first images of posts in same category
- How to display the category featured images [closed]
- How to hide my categories pages’ names, and how as well to reduce the space beween my sidebar’s widgets?