Click to See Complete Forum and Search --> : 2 css pages??


matty_y2002
07-26-2006, 12:33 PM
Can you have two css pages linked to a html document?
example can you have....

<head>
<meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
<title> my title</title>
<link type="text/css" rel="stylesheet" media="screen" href="./first.css" />
<link type="text/css" rel="stylesheet" media="screen" href="./second.css" />
</head>

Wiz Creations
07-26-2006, 01:38 PM
yes. is the . supposed to be there in href="./

nataliemac
07-26-2006, 02:18 PM
You can have as many stylesheets as you want.

But be aware that the stylesheet linked second will over-write any duplicate styles from the first stylesheet.

So, if you have a class named "red" in the first style sheet like this:

.red {
color: #FF0000;
font-size: 11px;
}
And a class named "red" in the second style sheet like this:

.red {
color: #CC0000;
font-size: 18px;
}
All of your elements with class "red" will have the attributes from the second stylesheet.

If you don't have any duplicate IDs or classes in your stylesheets, it won't make any difference at all.