HTML help..

Every site needs an off topic forum, right?
Post Reply
bennylenny88
Posts: 23
Joined: Tue Jan 06, 2009 8:56 pm
I drive a: GT 2.0 TSI
In: Candy White
With a: Manual box
Options: leather pack, floor mats
Location: Lowton/Manchester

HTML help..

Post by bennylenny88 »

i need a code to have a picture change when you scrollover it.. pleaseee
User avatar
Kev
Administrator
Posts: 5073
Joined: Fri Jul 25, 2008 5:25 pm
I drive a: GT 2.0 TSI
In: Rising Blue
With a: DSG box
Options: Leather, cruise, parking sensors, folding mirrors, flat tyre indicator
Sadly replaced now by an F-Type.
Location: Oxford

Re: HTML help..

Post by Kev »

That's called a rollover effect

http://www.htmlcodetutorial.com/images/ ... pp_62.html

Neater to use css though.
User avatar
rehmondo
Posts: 805
Joined: Wed Sep 03, 2008 1:36 pm
I drive a: GT 2.0 TSI
In: Candy White
With a: DSG box
Options: Leather • Winter • Sunroof • Cruise • DAB • Park • Tyre • Mirrors • Mats • Mudflaps • Prem Sills • Pedals • Jewelultra Diamondbrite • Bluefin Remap • Carbonio CAI • LED Pack
Location: Edinburgh

Re: HTML help..

Post by rehmondo »

Kev is right, css is much neater and much easier to manage.

Here's the first usable example I found for you on the net...

http://www.sohtanaka.com/web-design/css ... -captions/

Example working: http://www.sohtanaka.com/web-design/exa ... age-hover/

I've done things in the past using 1 image, but its made up of 3 smaller images, then using css it will show the bit you want to see using positioning, this means, when the page is rendered the image is loaded just once rather than 3 times for every link etc

I can go into further details but that link about should get you started, if you have trouble getting it, just reply back and I'll help you out - either by writing the code you need or helping you understand how it works.

I'm a senior developer in a software firm, our technologies rely on html/java/javascript heavily and we use css to manage a lot of cross browser issues rather than quick javascript fixes.

I take it it will be something not related to the forum?
User avatar
Kev
Administrator
Posts: 5073
Joined: Fri Jul 25, 2008 5:25 pm
I drive a: GT 2.0 TSI
In: Rising Blue
With a: DSG box
Options: Leather, cruise, parking sensors, folding mirrors, flat tyre indicator
Sadly replaced now by an F-Type.
Location: Oxford

Re: HTML help..

Post by Kev »

rehmondo wrote: I've done things in the past using 1 image, but its made up of 3 smaller images, then using css it will show the bit you want to see using positioning, this means, when the page is rendered the image is loaded just once rather than 3 times for every link etc
This forum uses the same principle

The new post button for instance is this
Image
and the rollover effect is achieved just by offsetting the image position.
Post Reply