Need Help Centering Layout

Discussion in 'HTML & Website Design' started by BrendanGall, Apr 24, 2009.

  1. #1
    I am working on a website for a local business and somehow i made the whole bottom half of the layout go to the left. Im sure its an easy css fix, but i just cant figure it out.

    Here is the site I am talking about.

    Any help would be greatly appreciated!
     
    BrendanGall, Apr 24, 2009 IP
  2. free3dart

    free3dart Active Member

    Messages:
    241
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    51
    #2
    Friend simply try Stylizer Ultimate, you will do it in seconds.
     
    free3dart, Apr 24, 2009 IP
  3. copspushmongo

    copspushmongo Peon

    Messages:
    118
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Put a div around it all, and use margin: 0 auto;
     
    copspushmongo, Apr 24, 2009 IP
  4. nathg

    nathg Peon

    Messages:
    5
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Try this <center>Your HTML code </center>
     
    nathg, Apr 24, 2009 IP
  5. copspushmongo

    copspushmongo Peon

    Messages:
    118
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    No dont, if youve got different width setting for your page, it can center wrong, and its also depricated.
     
    copspushmongo, Apr 24, 2009 IP
  6. BrendanGall

    BrendanGall Peon

    Messages:
    225
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #6
    I mean im ok at html css and i Normal can fix just about anything, but i just cant figure this out. Its all in a divs already.

    I tried text-align: center: all over the place. I know how to construct layouts and how themes work i just cant figure this out. I tried <center> although it is depreciated. I tried wrapping everything in a new divs < div style="text-align: center;">.

    It would be awesome if someone could look at it, maybe they can see something im not.
     
    BrendanGall, Apr 25, 2009 IP
  7. TheInsaneWebmaster

    TheInsaneWebmaster Peon

    Messages:
    26
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #7
    Copy and paste this for your HTML part of your code. You had one too many < / div > tags in there. This SHOULD take care of the centering issue. If it doesn't, let me know.

    <!-- Page -->
    <div id="page">
    
    	<!-- Header -->
    	<div id="header">
    	
    		<!-- Menu -->
    	<div>	
    <ul id="nav" class="clearfloat">
      <li><a href="http://www.builditgreennj.com/" class="on">Home</a></li>
    <li><a href="http://www.currentsnj.com/currents/advertise-with-currents-magazine/">About Us</a>
    
    <ul>
    
                            <li><a href="#">Who We Are</a></li>
                            <li><a href="#">Our STaff</a></li>                        
                           			
    		</ul>
    
    </li>
    <li><a href="http://www.builditgreennj.com/whats-hot/">Products</a>
    
    <ul>
                            <li><a href="#">Coupons &amp; Offers</a></li>
                            
    			
    		</ul>
    
    </li>
    <li><a href="http://www.builditgreennj.com/live/">Services</a>
    
    <ul>
    			<li><a href="#">Prodcuts</a></li>
                            <li><a href="#">Prodcuts</a></li>
    			<li><a href="#">Prodcuts</a></li>
    			<li><a href="#">Prodcuts</a></li>
                            <li><a href="#">Prodcuts</a></li>
                             <li><a href="#">Prodcuts</a></li>
                            <li><a href="#"><font color="green">Green</font></a></li>
    
    
    			
    		</ul>
    
    </li>
    <li><a href="http://www.builditgreennj.com/dine/">Design</a>
    
    <ul>
                            <li><a href="#">Service</a></li>
                            <li><a href="#">Service</a></li>
    			<li><a href="#">Service</a></li>
    			<li><a href="#">Service</a></li>
    			<li><a href="#">Service</a></li>
                            <li><a href="#">Service</a></li>
    			
    		</ul>
    
    </li>
    
    <li><a href="http://www.builditgreennj.com/shop/">Contact Us</a>
    
    <ul>
                            <li><a href="http://www.currentsnj.com/shop/">Contact us</a></li>
                            <li><a href="http://www.currentsnj.com/shop/coupons-offers-monmouth-county/">Our Staff</a></li>
    			
                       
    			
    		</ul>
    
    </li>
    
    
    <li><a href="http://www.builditgreennj.com/relax/">Link</a>
    <ul>
                            <li><a href="#">Link</a></li>
                            <li><a href="#">Link</a></li>
                                                   
    			
    		</ul>
    
    </li>
    
    
    
    
     <li style="float: right; text-align: right;">
    
    
    </li>
    </ul>
    </div>
    <div id="header-menu">
    
    			</div>
    		<!-- /Menu -->
    		
    		<!-- Title -->
    		<div id="header-info">
    			</div>
    		
    		<!-- /Title -->
    		
    		<!-- Topbar -->
    		
    		<!-- /Topbar -->
    	
    	</div>
    	<!-- /Header -->
    	
    	<!-- Main -->
    
    	
    	<div style="text-align: center; width: 100%;"><div style="width: 1004px;"><div id="main-bottom">
    		<!-- LEFT Sidebar -->
    
    
    
    <div class="sidebar">
    		
    			<h3>Green Design Studios</h3>
    			<ul>
    				<li class="page_item page-item-2"><a href="http://www.builditgreennj.com/about/" title="About">About</a></li>
    <li class="page_item page-item-11"><a href="http://www.builditgreennj.com/contact-us/" title="Contact Us">Contact Us</a></li>
    <li class="page_item page-item-45"><a href="http://www.builditgreennj.com/green-news/" title="Green News">Green News</a></li>
    <li class="page_item page-item-5"><a href="http://www.builditgreennj.com/products/" title="Green Products">Green Products</a></li>
    <li class="page_item page-item-56"><a href="http://www.builditgreennj.com/our-staff/" title="Our Staff">Our Staff</a></li>
    <li class="page_item page-item-9"><a href="http://www.builditgreennj.com/who-we-are/" title="Who We Are">Who We Are</a></li>
    			</ul>
    			
    			<h3>LINKS</h3>
    			<ul>
    			<li><a href="http://www.currentsnj.com">Currents Magazine</a></li>
                            <li><a href="http://www.buildinggreen.com">Building Green</a></li>
                            <li><a href="http://www.timbertech.com">Timber Tech</a></li>
                            <li><a href="http://www.pellawindows.com">Pella Windows</a></li>
    			</ul>
    			<br>
                          
    
    		</div>
    
    <!-- END LEFT Sidebar -->
    
    <!-- Begin Right Sidebar -->
    		
    <div style="width: 201px; margin-top: 6px; float: right;">
    
    
    <div style="background: rgb(19, 19, 19) none repeat scroll 0% 0%; width: 190px; text-align: center; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;">
    <div class="sidebar2">			
    			<h3>Partners</h3>
                            
                          
                            <center><img src="http://www.builditgreennj.com/ads/gac.jpg"></center>
                            <br>
                            <center><img src="http://www.builditgreennj.com/ads/buildingc1.jpg"></center>
                            <br>
                           <center><img src="http://www.builditgreennj.com/ads/pella-windows.jpg"></center>
                            <br>
                            <center><img src="http://www.builditgreennj.com/ads/adsize.jpg"></center>
                            <br>
    
    </div>
    
    						
    					
    		</div>
    </div>
    	<!-- End Right Sidebar -->		
    		<!-- Content -->
    		<div id="content">
    		
    									<!-- Post -->
    			<div class="post" id="post-1">
    				<div class="post-title">
    					<div class="post-date">
    						<span>20</span>
    						Apr					</div>
    					<h2><a href="http://www.builditgreennj.com/building-green/hello-world/" rel="bookmark" title="Permanent Link to "></a></h2>
    					Author: admin &nbsp;// &nbsp;Category: <a href="http://www.builditgreennj.com/category/building-green/" title="View all posts in Building Green" rel="category tag">Building Green</a>				</div>
    				<div class="post-entry">
    					<p>Welcome to the Green Design Studio.<span>&nbsp; </span>The one and only location for 100% green building products in the state of New Jersey.<span>&nbsp;&nbsp;&nbsp; </span>Located in Red Bank, Nj, our new showroom offers hundreds of building products that will make your NJ home more eco-friendly, energy efficient and beautiful.<span>&nbsp;&nbsp; </span>Among our tops selling products are:<span>&nbsp; </span>Timbertech, Build Block, and Pella energy efficient windows.<span>&nbsp;&nbsp;</span></p>
    <p class="MsoNormal" align="left"><strong>GREEN SERVICES<br>
    <span style="font-weight: normal;">Some Unique attributes to Green Design Showroom is we not only carry a full line of green products, but we can install them too.<span>&nbsp; </span>No matter what type of renovation you have: Decks, Additions, Flooring, Kitchens, Windows, Bathroom, Roofing, Siding and more, if it’s green we sell and install it.</span></strong></p>
    <p class="MsoNormal" align="left"><span>Frustrated with skyrocketing energy bills for your home or business?<span>&nbsp; </span>Concerned about the environment and what kind of planet you’re leaving behind for your children and want to know what you can do about it?<span>&nbsp; </span>Then it might be time for you to call the Green Design Studio in Red Bank, NJ and find out how you can Go Green. Click Here For More Information on Going Green</span></p>
    				</div>
    				<div class="post-info">
    					<a href="http://www.builditgreennj.com/building-green/hello-world/#respond" title="Comment on ">Comments (0)</a> &nbsp;// &nbsp;<a href="http://www.builditgreennj.com/building-green/hello-world/#respond">Add Comment</a>
    				</div>
    			</div>
    			<!-- /Post -->
    						<!-- Navigation -->
    			<div class="navigation">
    				<div class="navigation-previous"></div>
    				<div class="navigation-next"></div>
    		
    			<!-- /Navigation -->
    						
    			<div class="clear"></div>
    		
    		</div>
    		<!-- /Content -->
    	
    <br>
    
    </div>
    </div></div></div>
    Code (markup):
     
    TheInsaneWebmaster, Apr 26, 2009 IP
  8. TheInsaneWebmaster

    TheInsaneWebmaster Peon

    Messages:
    26
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #8
    Did this work out for you? No response back, was just curious.
     
    TheInsaneWebmaster, Apr 28, 2009 IP
  9. alexpr07

    alexpr07 Active Member

    Messages:
    284
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    73
    #9
    I don't see anything wrong with the site, I guess he fixed it.
     
    alexpr07, Apr 28, 2009 IP
  10. caratking

    caratking Active Member

    Messages:
    66
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    93
    #10
    I struggled with site layouts, browser issues etc. for years. Recently I found yahoo yui, if you have never checked it out you should. Yahoo has a team of people that works to produce this javascript and css tools, which it makes available for free.

    Want a centered page, multi-column... whatever you want it can do.

    They will even host the files for you. The CSS part is great, it totally make things standard. What works on one browser will work on all browsers.

    Just a tip, check it out.
     
    caratking, Apr 28, 2009 IP
  11. TheInsaneWebmaster

    TheInsaneWebmaster Peon

    Messages:
    26
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #11
    I suppose he did get it fixed. I dunno. Would have been nice to know if it helped. ask for help, get help and don't thank...lil problem there. but it happens I suppose.
     
    TheInsaneWebmaster, Apr 29, 2009 IP