Hi all, i'm trying to replace all my forum images with a sprite reference, most of my images are on forumhome, could someone help with how i'd present the css instead of this
HTML Code:
<td><img src="$stylevar[imgdir_statusicon]/$forum[imageprefix]forum_$forum[statusicon].gif" alt="" border="0" height="46px" width="46px" id="forum_statusicon_$forum[forumid]" />
</td>
here's a snippet of my sprite css
Quote:
.Accessforum_new{ background-position: 0 0; width: 47px; height: 47px; }
.Accessforum_old{ background-position: 0 -97px; width: 47px; height: 47px; }
.Excelforum_new{ background-position: 0 -194px; width: 47px; height: 47px; }
.Excelforum_old{ background-position: 0 -291px; width: 47px; height: 47px; }
.Outlookforum_new{ background-position: 0 -388px; width: 47px; height: 47px; }
.Outlookforum_old{ background-position: 0 -485px; width: 47px; height: 47px; }
|
HTML Code:
#td {
background: url(forumsprite.png) no-repeat top left;
}
So, not being any good whatsoever with css i'm assuming i'd reference the actual sprite like the code snippet above in my additional css? and how would i address the actual css references in the code snippet at the very top?
Any help is appreciated
EDIT: the image names in the css i.e
Accessforum_old are the names of the prefixes as they are currently in use.