Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 2 of 2
  1. #1
    Junior Member
    Join Date
    Jul 2010
    Posts
    2
    Member #
    22886
    I am in the process of designing a new theme for my wordpress powered site. I decided that it would make my life easier if I simply created an HTML page first so I already had most of the styling issues worked out and could then use that as a template for my new theme. The problem that I'm having is that when I run the the page it adds a small amount to width (only about 5 pixels or so). I'm not quite sure why it's doing it. I only want it to cover 100% of the page, not 100% plus a couple of pixels. The code is as follows:
    HTML Code:
    <html>
    <head>
    <style type="text/css">
    
    * {
    margin:0;
    padding:0;
    }
    body {
    background-color: #FFF;
    color: #000000;
    
    }
    #container2 {
    width: 100%;
    margin:0 auto;
    }
    #header {
    width: 100%;
    margin:0 auto;
    background: #FFF url(top.png) repeat-x;
    }
    #lotp {
    margin-left: 10;
    }
    #catch {
    width: 520px;
    position: relative;
    top: -130px;
    left: 200px;
    }
    #catch a {
    color: #FFF;
    }
    #rss {
    position:relative;
    top: -170px;
    float:right;
    margin-right: -12;
    }
    #navbar {
    position:relative;
    top:-37px;
    margin-left: 10;
    }
    #navbar a {
    text-decoration:none;
    padding-top:2;
    }
    #navbar a:hover {
    border-top:2px solid #0000CC;
    padding-top:2;
    }
    #container {
    width: 100%;
    }
    </style>
    </head>
    <body>
    <div id="container2">
    	<div id="header">
    		<div id="lotp"><img src="lotp.png" alt="LOTP" /></div><div id="catch"><a href="http://lotphelp.com"><h1>The Land of the Penguins</h1></a></div>
    		<div id="rss"><a <img src="rss.png" alt="RSS" /></div>
    		
    	</div>
    	<div id="navbar">
    			<a href="#">Home</a>&nbsp;|&nbsp;<a href="#">Test</a>
    	
    	</div>
    
    <div id="container">
    <div id="left">
    
    
    
    
    
    </div>
    <div id="right">
    
    
    
    
    
    </div>
    
    
    
    
    </div>
    
    </div>
    again, any help is greatly appreciated!

  2.  

  3. #2
    etm
    etm is offline
    Member
    Join Date
    Aug 2010
    Location
    Calgary, Canada
    Posts
    76
    Member #
    23011
    As a quick note to start, ensure all your units in your CSS file are defined. You have a lot of things like "margin-left: 2;" and sometimes that causes issue. It should be 2 px or 2 em or whatever the intention. The only value that doesn't need a unit is "0" because nothing is nothing regardless of unit.


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 11:05 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2020 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com