Revp
-
Posts
2 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Downloads
Gallery
Store
Posts posted by Revp
-
-
Hi all and thanks for having a place where beginners can ask questions.
I am very new to this and I have watched the video tutorial and read the others. I am designing my first website and enjoying learning css.
My problem is that I have written this page and css file in order to make a header and a nav bar on the left side. I have an image that I want as my background image which is in the correct folder. I also just want a plain color as the background in my nav bar. For the life of me I cannot figure out why it is not working. I have tried several things and have been researching and still can't figure it out. I was hoping someone here could help tell me where I am going wrong and let me know what I am missing or not understanding.
My css file cmcss.css --------------------------------------------------------------------------------------
/*
*/
#container {
width: 100%;
height: 100%;
margin: 0;
padding: 0;
border: 0;
}
/* */
#header {
width: 98%;
height: 20%;
border-top: 2px solid #000000;
border-bottom: 2px solid #000000;
border-left: 2px solid #000000;
border-right:2px solid #000000;
margin: 2%;
text-align: center;
font-weight: bold;
background-image: url(cmimgs/bright14.jpg);
}
#leftnav {
width: 20%;
height: 75%;
padding: 1%;
border-right: 2px solid #000000;
text-align: left;
font-weight: normal;
float: left;
background-color: #6495ed;
}
--------------- and then my index.html file ----------------------------
Thanks ahead of time for any help. I was expecting a big header with my image as the background and a left bar with a plain color background. Instead I get "My Name" and then my list right below it. The links are working. Its just that none of the styling is working. Thanks again for any help.
Having trouble
in Beginners Web Design
Posted · Edited by Revp
Thanks everyone for all the help. I got it to work lol.
THe missing quotes were on my html but I had accidently erased them when posting while I was going through to hide my name and website info. I wasn't sure on the policy of posting your website so I went through and hid it just to be on the safe side. I didn't want to break any forum rules.
I added the body tags to my html file
I took out the underline around my header because that was very sound advice Andrea thanks!
Thank you all so much it worked! I think it was the lack of body tags. Thats the only thing I can figure.
Boo yaa!!