Need Help Centering my index page???

This is a discussion on "Need Help Centering my index page???" within the Starting Out section. This forum, and the thread "Need Help Centering my index page??? are both part of the Design Your Website category.



 Subscribe in a reader

Go Back   Webforumz.com > Main Forums > Design Your Website > Starting Out

Notices


Reply
 
LinkBack Thread Tools
  #1  
Old Jun 5th, 2007, 14:15
Junior Member
Join Date: Jun 2007
Location: Florida
Age: 31
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Need Help Centering my index page???

Very new to webdesign and I thought what better way to learn then to design a webpage for my wife. Here is the site www.mommyandmimi.com If you look at the site you will notice that information box is not centered on the page. Does anybody know how to get this centered. Its driving me nuts and I have no way how to fix it. Thanks for listening!

Lee
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote

  #2  
Old Jun 5th, 2007, 14:21
Elite Veteran
Join Date: Jan 2007
Location: You know where
Age: 31
Posts: 4,617
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Need Help Centering my index page???

I'm not really sure I understand what it is that you want centered.

- The site pretty broken up in Firefox. Most of the images don't show up.
- The site doesn't validate. You have 96 errors
- No doctype (which tells the browser how to handle your code)

I could go on and on ...
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #3  
Old Jun 5th, 2007, 14:47
Junior Member
Join Date: Jun 2007
Location: Florida
Age: 31
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Need Help Centering my index page???

Hey there,
Thanks for the quick reply. The reason the page has so many problems is because my host is having issues and I have not been able to load anything for 30 hours now. I got to upload the page and then it crashed which is currently leaving me stuck with what I have.

I was basically referring to the centering of the page.......see how the all the text is to the left. I was wondering what I was doing wrong in order to get that to the center of the page.

Thanks everywhere
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #4  
Old Jun 5th, 2007, 14:54
Most Reputable Member
Join Date: May 2007
Location: UK
Age: 27
Posts: 1,111
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Need Help Centering my index page???

For centring the page, add this to your stylesheet:

Code: Select all
body {
margin: 0 auto;
}
Often that is not flexible enough. For more control, wrap a <div> around the stuff you want centred, and apply the style to it instead.

Don't have a stylesheet? You'll need to learn about them soon

**EDIT**

I see that you have already tried this, and it didn't work. Want to know why it didn't work? It's because you have no doctype.

You need to fix your site's many errors. To start with, put a correct doctype at the top of the page. This goes before anything else, even the <html> element:

Code: Select all
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
Without this, the method I gave you for centring won't work properly. That's an example of why cleaning up your code is important.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #5  
Old Jun 5th, 2007, 15:00
Elite Veteran
Join Date: Jan 2007
Location: You know where
Age: 31
Posts: 4,617
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Need Help Centering my index page???

Oh ok .. so just centering the whole site. Yeah you can do the margin: 0 auto on the body or wrapping a div around the whole thing

How to center your site horizontally
body can be used to style too!
Integrating CSS in your website

Depending on how much you want to get into this, you might want to ditch SiteBuilder and start hand-coding your site. WYSIWYG editors like SiteBuilder and Dreamweaver (using the Design View) really generate crappy code and leave you with endless errors.

Using Dreamweaver and the likes
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #6  
Old Jun 6th, 2007, 13:59
Junior Member
Join Date: Jun 2007
Location: Florida
Age: 31
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Need Help Centering my index page???

Thanks so much for the help. I was able to get the page centered.......now I can start working on the 8 million errors

Lee
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #7  
Old Jun 9th, 2007, 06:40
Elite Veteran
Join Date: Dec 2005
Location: On Internet
Posts: 4,859
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Need Help Centering my index page???

haha...Good luck!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply

Tags
centering, index, information box

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
index page help? Timmo88 Starting Out 1 Jun 4th, 2008 18:49
Centering a Page In CSS britishchampion Web Page Design 5 Jan 3rd, 2008 16:20
Centering an image on my web page Fysicus Web Page Design 8 Sep 21st, 2007 12:43
Index page coffee Classic ASP 1 Jun 7th, 2006 12:34
Centering layers in a page gwx03 Web Page Design 9 Nov 26th, 2003 19:55


All times are GMT. The time now is 23:28.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42