You are Approved for Debit Card! Enter Your Number.
Formatting Hyperlinks with Cascading Style Sheets (CSS)

Links are pieces of text that are hyperlinked to other web pages. They are 'clickable' meaning that a user can put their mouse cursor over the link, click, and go to the designated web page. There are four states that a link may be in on an HTML web page: the link, a visited link, an active link, and a hovered link.

The link, of course, is just the link as it appears when no action has been taken, and the cursor isn't over the link. The default color for links is blue, and they are usually underlined. However, with CSS, you can change this. A visited link is one that the user has visited, and it is usually no longer blue to the user - but it is still clickable.

An active link is a link that has just been clicked. The link turns a different color between the time that the user clicks the mouse button down and then let's goes of the mouse button, meaning that they have activated the link. A hovered link refers to the time that the user has their mouse cursor over a link, but has not clicked.

To manipulate these links, we use the following in our CSS:



a: link {color: #008000; text-decoration: none}
a: visited {color: #cccccc; text-decoration: none}
a: active {color: #ff0000; text-decoration: underlined}
a: hover {color: #3300ff; text decoration: underlined}

When we put the above code within our HTML web page CSS, all of the links on the web page will be green. When the user puts their mouse cursor over the link, it will turn blue, and be underlined. When they click the link, it will temporarily turn red and be underlined, and when they return to this page, the link that they clicked will be gray.
back next
WapMasters
Home
TOP
©CopyRight elektra2006-07®

!