+ Reply to Thread
Results 1 to 4 of 4

Thread: CSS Issues

  1. #1
    Junior Member
    Join Date
    Sep 2010
    Posts
    8

    CSS Issues

     
    Hello,

    I am working on a school project which requires me to make a four page site for a band using the same external CSS style sheet; all of which I have to write from scratch. For some reason my CSS doesn't seem to want to work properly. I have it posted below in hopes that someone can point out to me an error in the code that I am overlooking as well as the html code linking to it.


    HTML:
    Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <title>The Go Team</title>
    
    <link rel="stylesheet" type="text/css" href="css/styles.css"/>
    
    </head>
    
    <body>
    
    <div id="mainContain">
    
    <div id="header"><img src="images/header.jpg" /></div>
    <div id="navBar">Navagation Bar</div>
    <div id="centerContent">Stuff</div>
    <div id="footer">Footer</div>
    
    </div>
    
    
    
    </body>
    </html>
    CSS:
    Code:
    @charset "UTF-8";
    /* CSS Document */
    
    body,p,h1,h2,h3,h4	{
    	padding:0px;
    	margin:0px;
    	text-decoration:none;
    }
    
    .clear	{
    	clear:both;
    }
    
    #mainContain {
    	width:800px;
    	height:600px;
    	margin-right:auto;
    	margin-left:auto;
    	border: 2px solid #333;
    }
    
    #header {
    	width:800;
    	height:140;
    }
    
    #navBar {
    	width:800px;
    	height:20px;
    	background-color:#9F806B;
    }
    
    #centerContent {
    	width:800;
    	height:340;
    }
    
    #footer {
    	width:800;
    	height:100;
    	clear:both;
    	background-image:url(../images/footer.jpg);
    }
    To clarify a little. The problem that I am having here is that the div tags nested inside the mainContain div tag are not displaying at their proper heights and weren't even visible until I put text inside them.

  2. #2
    Junior Member
    Join Date
    Sep 2010
    Posts
    8
    It helps to put 800px instead of 800 etc etc. It's fixed now but thanks for looking if you did.

  3. #3
    Junior Member
    Join Date
    Sep 2010
    Posts
    2

    CSS

    Well, I would suggest you need to use Dream-weaver CS4 which allows you to create CSS compatible for all browsers. Good Luck.

  4. #4
    Junior Member
    Join Date
    Sep 2010
    Posts
    8
    I actually code in CS5. I just prefer to do my coding by hand because it helps me to remember things. Thank you for the suggestion though.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. help with css
    By Bob The Great in forum Webmastering and Programming
    Replies: 0
    Last Post: September 2nd, 2005, 04:41 PM
  2. css
    By sr71000 in forum Webmastering and Programming
    Replies: 11
    Last Post: August 10th, 2005, 03:39 PM
  3. css
    By ryanredbaron in forum General Gaming Discussion
    Replies: 3
    Last Post: September 4th, 2004, 05:15 AM
  4. Cross Browser CSS Issues?
    By Cyberlore in forum Webmastering and Programming
    Replies: 6
    Last Post: January 14th, 2004, 05:36 PM

Tags for this Thread

Posting Permissions

  • You may post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Recommended Sites: ResellerRatings Store Reviews