|
|
|
|
Joined: Nov 2002
Posts: 188
Member
|
|
Member
Joined: Nov 2002
Posts: 188 |
I am trying to come up with a way to use the onMouseOver command to display a background image in a section, rather than simply changing background colors...
I need to go from a solid color -- > IMAGE --> and back to the solid color for the onMouseOut command.
What I have so far, only change solid colors...
<TD BGCOLOR="#DEDFDF" VALIGN=MIDDLE ALIGN=MIDDLE WIDTH=100 onMouseover="this.style.backgroundColor='#CCE0FF'; this.style.cursor='hand';" onMouseout="this.style.backgroundColor='#DEDFDF'" onclick="window.location.href='http://www.gun-talk.com'"><A HREF="http://gun-talk.com">Icon Test 3</A></TD>
|
|
|
|
Joined: Nov 2000
Posts: 2,759
Pooh-Bah
|
|
Pooh-Bah
Joined: Nov 2000
Posts: 2,759 |
It might be easier to use the onMouseover and onMouseout to change the CSS class. That way you can set one class to display the background color and the other to display the background image.
|
|
|
|
|
Joined: Nov 2002
Posts: 188
Member
|
|
Member
Joined: Nov 2002
Posts: 188 |
After pulling out lots of hair, I finally figured it out... <TD BGCOLOR="#DEDFDF"VALIGN=MIDDLE ALIGN=MIDDLE WIDTH=100 onMouseover="this.background='fire.jpg'; this.style.cursor='hand';" onMouseout="this.background='#DEDFDF'" onclick="window.location.href='http://www.gun-talk.com'"><A HREF="http://gun-talk.com">Icon Test 1</A></TD> I had to remove the ".style" from both references, and then simoply substituted the image for the color code.
|
|
|
Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.
Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
|
|
Posts: 449
Joined: February 2008
|
|
|
Forums63
Topics37,583
Posts293,955
Members13,824
| |
Most Online151,614 Nov 14th, 2025
|
|
Currently Online 1193
Topics Created 0
Posts Made 0
Users Online 0
Birthdays 20
|
|
|
|
|
|
|
|
 |
 |
 |