Forum Moderators: not2easy

Message Too Old, No Replies

external css question

external style sheet

         

meanweaver

8:04 am on Oct 11, 2003 (gmt 0)

10+ Year Member



I have some code that works fine on an internal style sheet, but the time has come to use an external sheet. I have created a link to the external stlye no problem, I have then cut and pasted the code onto this sheet, the only problem now is only the code for the body will not work, I have tried everything to get the code for the body to work, I'm no expert at this but am I overlooking the obvious, here is the code i'm using

<style>
body {font:20pt;font-family:sans-serif;color:green;

h1 {font:"42";color:"red";font-family:"impact";}

A:link, A:visited {text-decoration: none; color:#063ea5;}
A:hover {font-weight: none; color:#CC3300; text-decoration: underline;}

</style>

Regards Ian

MonkeeSage

8:17 am on Oct 11, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



The <style> element is for HTML only, for an external stylesheet all you need is the style rules. Just dump the HTML tags and leave everything in between them and you should be set.

Ps. Looks like you missed the closing squiggly brace ('}') on your body rule.

Jordan

meanweaver

8:48 am on Oct 11, 2003 (gmt 0)

10+ Year Member



Thank you very much, I dropped the html tags and now everythings working a treat, The missing } on my body was just a copy and paste error i made, but i have spent hours working on this, it all makes sence now i know where i was going wrong. Thanks again.