OH2D Posted November 27, 2010 Share Posted November 27, 2010 Hi all, When i specify a background color for the body in CSS it does not show up. However when i don't specify a !DOCTYPE the background color does show up. What do i have to do to get it to show up? One other piece of info...if i do specify a background image in CSS it does show up. Thanks guys! Link to comment Share on other sites More sharing options...
0 iuerg87yerg879e0rg9erugjer Posted November 27, 2010 Share Posted November 27, 2010 lol why do people do this... without the css source code we really cannot do anything our end... Link to comment Share on other sites More sharing options...
0 OH2D Posted November 27, 2010 Author Share Posted November 27, 2010 lol why do people do this... without the css source code we really cannot do anything our end... Lol yeah i realized i didnt right after i posted sorry :p any way here it is: /* CSS DOC */ body{ background-color: 0d6379; } #pagewrap{ width: 800px; height: 610px; margin: 0 auto; } #container{ width: 800; height: 610px; float: left; } #content{ width: 530px; height: 570px; float: right; background-color: red; } #logo{ width: 270px; height: 180px; background-color: white; } /* NAVIGATION START */ #nav_bg{ width: 270px; height: 210px; } #nav{ margin-top: 0px; margin-left: -2.5em; list-style-type: none; } #nav li{} #nav a{ display: block; height: 30px; width: 270px; } #nav a.home{ background-color: black; } #nav a.on-site{ background-color: green; } #nav a.company{ background-color: black; } #nav a.quality{ background-color: green; } #nav a.premium{ background-color: black; } #nav a.engineering{ background-color: green; } #nav a.contact{ background-color: black; } /* NAVIGATION END */ #info{ background-color: blue; width: 270px; height: 180px; } #footer{ background-color: orange; width: 800px; height: 40px; } Link to comment Share on other sites More sharing options...
0 Mr aldo Posted November 27, 2010 Share Posted November 27, 2010 You forgot the # body{ background-color: #0d6379; } Link to comment Share on other sites More sharing options...
0 iuerg87yerg879e0rg9erugjer Posted November 27, 2010 Share Posted November 27, 2010 You forgot the # body{ background-color: #0d6379; } yep, sure did remember you need to put a # infront of any hex colours :D Link to comment Share on other sites More sharing options...
0 OH2D Posted November 27, 2010 Author Share Posted November 27, 2010 You forgot the # body{ background-color: #0d6379; } OHHH DERP!! Thanks!!! :yes: Link to comment Share on other sites More sharing options...
Question
OH2D
Hi all,
When i specify a background color for the body in CSS it does not show up.
However when i don't specify a !DOCTYPE the background color does show up.
What do i have to do to get it to show up?
One other piece of info...if i do specify a background image in CSS it does show up.
Thanks guys!
Link to comment
Share on other sites
5 answers to this question
Recommended Posts