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.

.Mine CSS code

NimaveliNimaveli New
edited August 2010 in Vanilla 2.0 - 2.8
Hey, I'm having a slight problem with this code. I changed the background of the .Mine code to something different than normal so your own posts stand out a little bit more. But, the problem is that this also changes the background of your own topics. I don't want that, is there any way to have this CSS code only affect your own posts?


  • Options

    ul.MessageList li.Mine {background-color: #AABBCC;}
  • Options
    Thanks for the reply! But no, that code doesn't work unfortunatly D:
  • Options

    ul.MessageList li.FirstComment {background-color: #XXXXXX; }

    either at the bottom of your css file (which will make it load after the other color)
    or in a new file, custom.css (this is automatically used, if present, and loads after the other css files.)
  • Options
    Putting it at the bottom of my CSS file worked! Thanks! :)
  • Options
    not a problem ;)
  • Options
    @zodiacdm Wouldn't your method simply change the background-color of every first comment rather than ones written by the author. It wouldn't apply to the 3rd or 6th comments.

    @Nimaveli I just put my method into a custom.css file and it worked straight away.
  • Options
    @Caramboo Well, yes it would.

    Say .Mine has been changed to blue, other posts are white. If you set .FirstComment to white after .Mine, it will ignore the blue defined in .Mine, and use white for all first comments.

    Since there are multiple classes assigned to most objects in Vanilla2, you will find that just about anything that shares classes will also have a separate individual one. This is so that you can do exactly this; override the previous style to make the objects differ.
Sign In or Register to comment.