body {
background-color: #BDB76B;
font-family: Arial, Verdana, Sans-serif;
font-size: 18pt;
color: #00008B;
}Why is my CSS not rendering in my web page?
How is your CSS code setup? Are you importing it or is it part of the html/php document? Otherwise it looks fine. Personally I would use px or em instead of pt though.Why is my CSS not rendering in my web page?
your HTML file should look like this:
%26lt;html%26gt;
%26lt;head%26gt;
%26lt;style type=';text/css';%26gt;
body {
background-color: #BDB76B;
font-family: Arial, Verdana, Sans-serif;
font-size: 18pt;
color: #00008B;
}
%26lt;/style%26gt;
%26lt;/head%26gt;
%26lt;body%26gt;
Hello Annie O!
%26lt;/body%26gt;
%26lt;/html%26gt;
The css itself looks fine. How are you calling to the style in your HTML? Is it in an external style-sheet, or is it in the HTML document itself? That's where I'd look first. If you have refered to the style sheet incorrectly then it won't render.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment