Previous Message
Next Message

href's and images

Sent by Gunlaug_Sørtun on 21 September 2005 13:01


Sam Leathers wrote:
> I'm working on a website where I have a standard <ul> list for links
> in display: block; Currently, the links are <img> tags, but I'd like
> to use css to display the image. I know I can use background: 
> url("/path/to/image.gif"), but whats the best way to have a different
>  image for each href? Do I need to have each href in a different
> class to achieve this? Also, if it makes any difference, I do plan on
> using the hover tag to do an image swap.
> 
> URL: http://irc.gentux.org:8000/Contact-pg.html

You can achieve this -- including hover-change -- by creating one, large
image and position it differently based on a class and the state for
each href. It just sound complex -- it really isn't ;-)

Think this is the info you need:
<http://www.alistapart.com/articles/sprites>

	Georg
-- 
http://www.gunlaug.no
______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Previous Message
Next Message

Message thread: