Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
Old 08-08-2007, 06:47 PM Rollover images
Skilled Talker

Posts: 58
Trades: 0
Hi,

I'm converting a website (http://www.dfwpurebredrescue.org/) to CSS and want to get rid of the tables. I'm very new to CSS, and I'm having trouble with the navigation bar.

Using an unordered list I was able to align the normal images, but couldn't get the images to rollover. So then I tried some other tutorials that just had text links in hopes I could figure out how to change it to use images ... and now I'm really lost and pretty much back at the beginning.

Any help would be greatly appreciated! Thank you.
lilycup is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 08-08-2007, 07:13 PM Re: Rollover images
Super Talker

Posts: 122
Name: Nate
Location: Orlando, FL
Trades: 0
I've found some of these to be very useful...

http://www.dynamicdrive.com/style/cs...y/category/C1/
NateL is offline
Reply With Quote
View Public Profile
 
Old 08-08-2007, 09:59 PM Re: Rollover images
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
No scripting necessary, you can do image rollovers with just css.

You can use plain text and use the a:hover pseudo-class to change the text color when you roll over the button.

So your CSS would look something like this:

li a:link{
color: #dacae6; /* sets text color to lavender*/
}

li a:hover{
color: #cfe5ae; /*sets text color on mouse over to pale green*/
}

No images necessary and you have readable, accessible TEXT.

You might want to try out this tutorial on lists:
http://css.maxdesign.com.au/listutorial/
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 08-09-2007, 10:06 AM Re: Rollover images
Angelosanto's Avatar
Webmaster Talker

Posts: 548
Name: Danny Angelosanto
Trades: 0
Thats right, but if you really want to use images, then it is possible to do so with CSS. I am about to write a blog post on this, so I'll explain in more detail there, but if you design an image that contains both the images involved (so for example, the original image on top of the desired rollover image, all in one picture) then you can use the background-position property to create a rollover effect.

For a good example of the use of this, go to Glush.tv, then have a look at the search button at the top.

Main Site
The Image
The CSS

The CSS part is under 'input.button'

Hope it helps, its a great little method
__________________
"The only reason some people get lost in thought is because it's unfamiliar territory."
_____________________________________
Angelosanto is offline
Reply With Quote
View Public Profile Visit Angelosanto's homepage!
 
Old 08-09-2007, 11:13 AM Re: Rollover images
fitnfree's Avatar
Ultra Talker

Latest Blog Post:
Almond Cookie Recall
Posts: 384
Name: Jeni
Location: Wisconsin, USA
Trades: 0
That's interesting, angel -- thanks. Never saw this done like that (with one image). I'll have to keep an eye on your blog for that blog post on this -- thanks.
__________________

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
fitnfree is offline
Reply With Quote
View Public Profile Visit fitnfree's homepage!
 
Old 08-09-2007, 11:55 AM Re: Rollover images
Angelosanto's Avatar
Webmaster Talker

Posts: 548
Name: Danny Angelosanto
Trades: 0
Quote:
Originally Posted by fitnfree View Post
That's interesting, angel -- thanks. Never saw this done like that (with one image). I'll have to keep an eye on your blog for that blog post on this -- thanks.
No probs - I'll let you know when I've written it
__________________
"The only reason some people get lost in thought is because it's unfamiliar territory."
_____________________________________
Angelosanto is offline
Reply With Quote
View Public Profile Visit Angelosanto's homepage!
 
Old 08-09-2007, 01:41 PM Re: Rollover images
Skilled Talker

Posts: 58
Trades: 0
Thank you, everyone, I really appreciate the help!
lilycup is offline
Reply With Quote
View Public Profile
 
Old 08-09-2007, 02:24 PM Re: Rollover images
fitnfree's Avatar
Ultra Talker

Latest Blog Post:
Almond Cookie Recall
Posts: 384
Name: Jeni
Location: Wisconsin, USA
Trades: 0
Quote:
Originally Posted by Angelosanto View Post
No probs - I'll let you know when I've written it
That'd be great Angel, thanks again!
__________________

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
fitnfree is offline
Reply With Quote
View Public Profile Visit fitnfree's homepage!
 
Old 08-09-2007, 03:12 PM Re: Rollover images
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
The method Danny mentioned is called Sliding Doors - I believe it was first mentioned here: http://www.alistapart.com/articles/slidingdoors/
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 08-10-2007, 02:10 PM Re: Rollover images
DrSeuss's Avatar
Skilled Talker

Posts: 60
Name: Matt
Trades: 0
This could be used for my drop down menu header rollovers on the site I'm working on right?

I would really like to recreate my menu in CSS and dump the javascript, but it seems like it will take some time to figure out how to do that...
DrSeuss is offline
Reply With Quote
View Public Profile
 
Old 08-10-2007, 03:57 PM Re: Rollover images
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
Dr. Seuss you could, in fact, use a CSS method for your menu w/o using the mess of JS you have now.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Rollover images
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.32133 seconds with 12 queries