Need to change font-weight on mouseover in TD
I'm updating a web site and the customer wants the font weight to change to BOLD on mouseover. The existing code looks like:
...which I modified to...
...which doesn't work.
Maybe I've been looking at this too long and just don't see what I've done wrong.
Thanks in advance for your help!
John
Busy posted this at 19:47 — 21st February 2006.
He has: 6,151 posts
Joined: May 2001
Wouldn't it be easier to make use of CSS's hover (a:hover)
robfenn posted this at 21:31 — 21st February 2006.
He has: 471 posts
Joined: Jun 2005
Yes, do it in CSS. If you only want it for a particular part of text then create a class.
e.g:
p.title {font-family: arial; font-size: 11px; color: #FF6101; text-decoration: none; text-align: justify;}
p.title a:link {color: #FF6101; text-decoration: none;}
p.title a:visited {color: #FF6101; text-decoration: none;}
p.title a:hover {text-decoration: underline; color: #FF6101; font-weight:700;}
p.title a:active {color: #FF6101;text-decoration: none;}
john3000 posted this at 16:52 — 22nd February 2006.
He has: 4 posts
Joined: Jul 2005
Thanks!
Hmmm. I'm not sure what I'm doing wrong. Last night I set up a class, as recommended, but now it appears that there must be a problem with the class, as it appears as if it is being ignored. I thought getting some sleep would help, but it didn't ...still working on it...
Busy posted this at 20:10 — 22nd February 2006.
He has: 6,151 posts
Joined: May 2001
If you used the code above you'd have to use Google
I personally would leave the p out and just use it in a span or div (would change css style to a.title:link ...)
john3000 posted this at 21:33 — 22nd February 2006.
He has: 4 posts
Joined: Jul 2005
I think I need new eyeballs. It took me a long time to find the problems in the lines below.
p.secrtop a:hover {text-decoration: nouunderline; color: #FFFFFF; font-weight:700;}
Some days the brain sees what it wants to see, not what's really there. Like the extra "u" in nounderline or the missing "r" in the class name "sectop" which should be "secrtop."
Maybe more sleep would be a good idea... Thanks for all the help!
Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.