2

Is there a way to assign an icon to a category post as well as the posts original image that's set in the featured images?

So if had a post about grapes I would have an image of some grapes in the thumbnail but I'd also have a grape icon from the grapes category attached to the preview post. This is an example of what I mean http://wordpress.thebebel.com/showcase/bloggaexport/

Thanks

2

As far as I can see from the link you mentioned, there are no icons for categories, only avatars for authors. Is that what you mean? If you do want category icons, take a look at some plugins in the WordPress.org directory. Here's an example: http://wordpress.org/extend/plugins/category-icons/

  • Sorry that's probably me misinterpreting that author avatars as categories. Thanks for the links I'll check those out if I can't do Miha's suggestion. – a_knife_a_fork Oct 10 '12 at 10:18
1

You could do that in template. Have an array of $category_icons = (category_id => url_to_icon,…) and then where you want to show the icon, you just use <img src="<?$category_icons[$cat_id]?>"> where $cat_id would be the current category ID.

  • Cool thanks Miha, I'll give that go and see how it goes. – a_knife_a_fork Oct 10 '12 at 9:59
0

You can use a plugin such as this:

http://wordpress.org/extend/plugins/taxonomy-images/

These plugins work by adding a term meta table, then adding a meta key/value holding the ID of an attachment, the same way featured images work with posts, but for taxonomy terms

0

You could also set a background image with the auto-generated css class category-slug in your stylesheet

  • Please elaborate how this would be "auto generated". – kaiser Jun 25 '13 at 22:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.