|
Standard links can be boring, or might not fit in with the rest
of the page. Now, with Cascading Style Sheets, you can change
all that in a flash!
Firstly, let's make links that aren't underlined. However, be
aware of the dangers of this - some people may miss links that
are not underlined. Because of this, mirrormere.com's links
are normally underlined, and only change to not being underlined
when you move the mouse over them in Microsoft Internet Explorer 4
or higher.
To implement non-underlined links, add this code to the <head>
of your file:
<style type="text/css">
<--
A {text-decoration: none};
-->
A link on your page when this code is used would look something like this (the
link will only change colour if you move the mouse over it in Microsoft Internet Explorer 4 or above because of our
site-wide link format):
A non-underlined link
But what about the links that change style in newer versions of
Microsoft Internet Explorer? To create links like ours on mirrormere.com, try using the code:
<style type="text/css">
<--
A:hover {color: red};
-->
That will produce this sort of link (mouse over it in Microsoft Internet
Explorer 4 or higher to see the effect):
A changing link
You can use the same technique to change other HTML tags in the same way! Here's a
<b> tag that's not bold - check the source code if you don't belive me!
Not a bold tag at all!
|