Jump to content

Link color


Fire Dragon

Recommended Posts

This is pretty easy question but how I can change link's color when mouse is over it?ONMOUSEOVER event comes first to my mind but then I must change every link's code.I also heard there is code what like automatically defines color change for all page's links.Is this kind code possible and is HTML or JS needed for it?

Link to comment
Share on other sites

You can change the color of all your links with This goes in an external style sheet without the <style> tags or within your html page. External stylesheet is recommended.

<style type="text/css">a:link { color: #000000; text-decoration: none; }a:visited { color: #000000; text-decoration: none; }a:active { color: #000000; text-decoration: none; }a:hover { color: #000000; text-decoration: underline; }</style>

a:hover is when your mouse is hovers over the link. text-decoration: underline means the link is underlined and none means no underline.

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...