CSS Stylesheet Problem

liunx

Guest
Hello,

I'm trying to change my current CSS Stylesheet link, which is a server-side include, to be a rel link like this:
<link rel="Stylesheet" type="text/css" href=http://www.webdeveloper.com/forum/archive/index.php/"ScriptLibrary/stylesheet.css"/>

The problem is that for some reason, the regular link's color isn't showing up on the page when I change the stylesheet from a SSI to a REL link. Can anyone explain why this is happening? I'm confused, because the link color works fine with the SSI setup. For review, the content is below. Thanks.

KWilliams

Here's a link to a page that displays my problem. See the 1st link for the issue:
<!-- m --><a class="postlink" href="http://www.douglas-county.com/example.asp">http://www.douglas-county.com/example.asp</a><!-- m -->
..But if you go to my home page, you'll see what the regular sized links look like with a SSI instead of the REL link:
<!-- m --><a class="postlink" href="http://www.douglas-county.com/index.asp">http://www.douglas-county.com/index.asp</a><!-- m -->

I've also tried the following syntax with the css stylehseet, but it didn't solve the issue: (:link)
a:link {font-family: "Arial"; font-size:12px; font-style:normal; font-weight:normal; letter-spacing:normal; text-decoration:underline; color:330066; }
a:hover {color:ff0000; text-decoration:none;}
a.small:link {font-family: "Arial"; font-size:10px; color:330066; text-decoration:underline;}
a.small:hover {font-family: "Arial"; font-size:10px; color:ff0000; text-decoration:none;}

Current CSS Stylesheet:
<style type="text/css">
a {font-family: "Arial"; font-size:12px; font-style:normal; font-weight:normal; letter-spacing:normal; text-decoration:underline; color:330066; }
a:hover {color:ff0000; text-decoration:none;}
a.small {font-family: "Arial"; font-size:10px; color:330066; text-decoration:underline;}
a.small:hover {font-family: "Arial"; font-size:10px; color:ff0000; text-decoration:none;}
p {font-family: "Arial"; font-size:12px; font-style:normal; font-weight:normal; letter-spacing:normal; text-decoration:none; color:000000;}
p.small {font-family: "Arial"; font-size:10px; font-style:normal; font-weight:normal; letter-spacing:normal; text-decoration:none; color:000000;}
p.red {font-family: "Arial"; font-size:10px; font-style:normal; font-weight:normal; letter-spacing:normal; text-decoration:none; color:ff0000;}
div.red {font-family: "Arial"; font-size:10px; font-style:normal; font-weight:normal; letter-spacing:normal; text-decoration:none; color:ff0000;}
td {font-family: "Arial"; font-size:12px; font-style:normal; font-weight:normal; letter-spacing:normal; text-decoration:none; color:000000;}
li {font-family: "Arial"; font-size:12px; font-style:normal; font-weight:normal; letter-spacing:normal; text-decoration:none; color:000000;}
h1 {font-family: "Arial"; font-size:16px; font-style:normal; font-weight:bold; letter-spacing:normal; text-decoration:none; color:660000;}
h2 {font-family: "Arial"; font-size:14px; font-style:normal; font-weight:bold; letter-spacing:normal; text-decoration:none; color:000000;}
h3 {font-family: "Arial"; font-size:12px; font-style:normal; font-weight:bold; letter-spacing:normal; text-decoration:none; color:ffffff;}
h4 {font-family: "Arial"; font-size:10px; font-style:normal; font-weight:bold; letter-spacing:normal; text-decoration:none; color:ff0000;}
INPUT, TEXTAREA {
font-family: "Arial";
padding: 1px;
font-size: 12px;
color: #000000;
background-color: #FFFFFF;
border: inset 2px #660000;
}
</style>When you use an external style sheet you should remove the html style tags...

<style type="text/css">

and

</style>

Then it should work :DHi Dave,

Thanks for the really quick response. I actually don't have any <HTML> tags on the stylesheet page. Just <style type="text/css"> AND </style>. The page that has the link on it has this in the head tag:
<link rel="Stylesheet" type="text/css" href=http://www.webdeveloper.com/forum/archive/index.php/"ScriptLibrary/stylesheet.css"/>

...is that how it's supposed to go? Thanks for your help.

KWilliamsIf you're changing from SSI's to links, you should remove the <style> and </style> tags inside your CSS. They're needed in SSI's because that just inserts the include into the HTML going out, but they're understood to be present in the link (since you're declaring them as RELationship="stylesheet")

We use CSS's quite liberally on sites we maintain, and they're great stuff... haven't had to use a <font> tag in years! <grin>

I hope that helpedOk, I'll try that, and let you know the outcome. I'm changing my entire site to use one CSS Stylesheet, and it's been great. It takes so much less work to maintain in the long run, and everything loads faster. Thanks for your input...I'll let you know.

KWilliamsLOL when I said remove the html style tags I meant
<style type="text/css">

and

</style>

LOL

Should have made that clearer LOL
 
Back
Top