CSS Hover

a:hover
{
background-color:red;
}

Try rolling over here to see the effect

  • The :link selector can be used to style links on unvisited pages

  • The :visited selector indicates a page already visited, most keep this the same as :link

  • The :active link selector is used to style an active link, this is rarely used and is red by default. When you click a link it becomes active for a millisecond, if you go to google and perform a search, go to the bottom to view the second page, pay close attention when you click a link, you will notice foir a brief second the link turns red.

  • The :hover selector is not secluded to links, the hover selector can be used on other elements

  • For the hover selector to be successful it must fall after the :link and :visited selectors if they are present

Note some browsers will have compatibility issues with the :hover selector and some additional settings within the browser may be required to be altered to allow the use of javascript.

Google Ads

Connect with helpvid

you tubefollow our twitter tweets

Most Valuable Keywords Study

make money online