user4fun Posted February 1, 2006 Share Posted February 1, 2006 I cannot find an example for mouse over font changes with javascript? or shouldibeusing something elsei just need for fon to change color to red and lose the underlining when mouse is overthank you all Link to comment Share on other sites More sharing options...
scott100 Posted February 1, 2006 Share Posted February 1, 2006 I cannot find an example for mouse over font changes with javascript? or shouldibeusing something elsei just need for fon to change color to red and lose the underlining when mouse is overthank you all<{POST_SNAPBACK}> You can do this with JavaScript but you should use css for page appearance.<html><head><style type="text/css">a:link {color: black;text-decoration: underline}a:visited {color: black;text-decoration: underline;}a:hover {color: red;text-decoration:none}a:active {color: red;text-decoration:none}</style></head><body><p><b><a href="#">This is a link</a></b></p></body></html> Link to comment Share on other sites More sharing options...
user4fun Posted February 1, 2006 Author Share Posted February 1, 2006 <code>Thank you so much for your help, and if you would be so kind to help me with one more questionI tried to change the original color to blue instead of black and it stoped working<body><style type="text/css">a:link {color: auto;text-decoration: underline}a:visited {color: auto;text-decoration: underline;}a:hover {color: red;text-decoration:bold}a:active {color: red;text-decoration:none}</style><p><b><a href="presult.htm"><font color="#0000CC">Result</font></a></b></p><p><b><a href="cal.htm">Cal</a></b></p></code>and i am also trying to limit that to the link on vertical bar just like the one on this site where it sayslearn htmllearn csslearn javascriptetcetcetc Link to comment Share on other sites More sharing options...
aspnetguy Posted February 1, 2006 Share Posted February 1, 2006 a:link {color: blue;text-decoration: underline}a:visited {color: blue;text-decoration: underline;} Link to comment Share on other sites More sharing options...
user4fun Posted February 2, 2006 Author Share Posted February 2, 2006 a:link {color: blue;text-decoration: underline}a:visited {color: blue;text-decoration: underline;} <{POST_SNAPBACK}> is there a specifc way to limit it to certain links instead of all of the links on the page? Link to comment Share on other sites More sharing options...
Err Posted February 2, 2006 Share Posted February 2, 2006 Link: http://www.w3schools.com/css/css_pseudo_classes.aspYou should use that as a reference. a.main:link {color: blue;text-decoration: underline}a.main:visited {color: blue;text-decoration: underline;}a.main:hover {color: blue;text-decoration: none;} you need to apply the class property to the links like this: <a class="main" href="#">Link Text</a> Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now