Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Is there a plugin which enables individual images / icons for categories?

Im looking to see if there is a plugin or a way to make each category have their own individual category icon.

For example,

(Apple Logo) Apple

(Blackberry Logo) Blackberry

(HTC Logo) HTC

Anyone know of any info?

Thanks :)
Tagged:

Answers

  • ToddTodd Chief Product Officer Vanilla Staff
    There isn't something like this now, but we'll be adding more css in future versions.
  • A quick hack/suggestion:

    Make in your template a custom
    /themes/mytheme/views/categories/discussions.php

    Find the div with class : CategoryBox

    Add a data-info attribute to it:

    data-info="CategoryID<?php echo $Category->CategoryID; ?>"

    Now that looks like:

    UrlCode; ?>" data-info="CategoryID_<?php echo $Category->CategoryID; ?>">


    This will add the number of the category like data-info="CategoryID_13"

    -------------
    Now add CSS

    For example :
    div[data-info~="CategoryID_1"] {margin-left: 2px; border-left: 2px solid red; }
    will give a red strip on the left of the DIV

    Change CSS to your needs.

    Cheers


  • Which reminds me : why is the CategoryparentID not available in $Category?
    This would ease things because then you could style all children in one time...
  • @nepwk : make a quick bug report @ gitHub maybe they can still add it to 2.0.18 version
  • Hi, can someone please elaborate this one for me? Since I dont quite know how to do this and there are very little info on how to create custom template.
    As in what shall I use for starting point for discussions.php ?

    Thanks in advance.
  • @nepwk I can't get this to work. Any suggestions? Thanks!
Sign In or Register to comment.