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.

Theme sprite replacement - best practices?

RajioRajio
edited June 2011 in Vanilla 2.0 - 2.8
I'm creating a new theme and Its pure CSS so far, no images used other than the logo which was uploaded from the dashboard, and the favicon which I just needed to include in my theme folder. I want to replace star_sprite and buttons.png with ones matching my theme. Whats the best way to do this?

I don't want to write out a full theme path in my css file, that doesnt seem ideal.
Tagged:

Answers

  • lucluc ✭✭
    inside your theme, create the subdirs exactly as where you find them (design/images?, images?) don't for sure, I don't have access to a theme, but I'm pertty sure it's covered in the themes doc.
  • RajioRajio
    edited June 2011
    Ive added star_sprite.png to /design/images in my theme, and added

    a.Bookmark,
    a.Bookmarked,
    a.Bookmarking {

    background: url('images/star_sprite.png') top center no-repeat;

    }

    to custom.css ... the only result is that the star sprite is changed to the new image but won't change states now. i cant seem to fidn the css for different states.
  • Solved it;

    Need to also add

    a.Bookmarked {
    background-position: center center;
    }
    a.Bookmarking {
    background-position: bottom center;
    }

    to custom.css
Sign In or Register to comment.