Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 03-16-2005, 01:39 PM   PM User | #1
Marc84
New to the CF scene

 
Join Date: Mar 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Marc84 is an unknown quantity at this point
Trying to get my site working in firefox

Hello everybody
I'm trying to get my site working in firefox. My site is: http://www.beltonenplaza.com/ I've got the following problems:

- As you can see in firefox the website is centered left, but it should be in the middle. I've tried DIV { text-align: center; } but it doesn't work.

- The "Zoek!" button is placed totally left. It should be under the rest of the text.

- The text above the orange lines are placed in the bottom of the table. They should be in the middle. I've tried vertical-align: middle; but that doesn't work.

I hope you can help me with this.

Thanks.
Marc84 is offline   Reply With Quote
Old 03-16-2005, 01:50 PM   PM User | #2
evo
waka Ionsurge


 
Join Date: Feb 2005
Location: United Kingdom
Posts: 881
Thanks: 5
Thanked 12 Times in 12 Posts
evo is an unknown quantity at this point
For whatever is your outer table -- add: "margin: 0px auto" which will align the table to center.

As for the button, use padding-left, or margin-left to get it to where you want it to.

Or you could wrap it in a <div> which has margin: 0px auto in it.
evo is offline   Reply With Quote
Old 03-16-2005, 01:59 PM   PM User | #3
ronaldb66
Senior Coder

 
Join Date: Jun 2002
Location: The Netherlands, Baarn, Ut.
Posts: 4,253
Thanks: 0
Thanked 0 Times in 0 Posts
ronaldb66 is an unknown quantity at this point
Margins

The proper way to center-align a block level element like a div is to specify auto left and right margins; since the outer div seems to be the only one, this would set top and bottom margins to zero and left and right to auto:
Code:
margin: 0 auto;
Text-align should only apply to inline content; IE incorrectly applies this to block level elements as well.

You should really look into CSS a bit more; margins and padding go a long way in replacing junk like this:
Code:
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
Quote:
The text above the orange lines are placed in the bottom of the table.
What text above which orange lines? You mean the h2's? In IE everything shows up sort-of-alright, but it sure can be done a lot simpler; again, padding would go a long way into getting everything to line up nicely.

Edit:
Looks like you've beaten me, evo...
__________________
Regards,
Ronald.
ronaldvanderwijden.com

Last edited by ronaldb66; 03-17-2005 at 08:22 AM..
ronaldb66 is offline   Reply With Quote
Old 03-16-2005, 02:48 PM   PM User | #4
Marc84
New to the CF scene

 
Join Date: Mar 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Marc84 is an unknown quantity at this point
Thanks, i got rid of all the &nbsp;'s, now i'm working on the rest.
Marc84 is offline   Reply With Quote
Old 03-16-2005, 02:55 PM   PM User | #5
Marc84
New to the CF scene

 
Join Date: Mar 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Marc84 is an unknown quantity at this point
I still can't get the website centered. I tried <div style=" margin: 0px auto"> but that didn't work. What did I do wrong?

EDIT: I've got it! I added this: padding: 0; width: 750px;

Last edited by Marc84; 03-16-2005 at 03:03 PM..
Marc84 is offline   Reply With Quote
Old 03-16-2005, 03:03 PM   PM User | #6
JamieR
Senior Coder

 
JamieR's Avatar
 
Join Date: Oct 2004
Location: United Kingdom
Posts: 3,161
Thanks: 0
Thanked 5 Times in 5 Posts
JamieR is on a distinguished road
My advice is to get rid of ALL the tables and totally recode the layout using css for layout..
btw, whats with the huge number of <br /> tags? CSS is best used for that, if you want to apply a lot of breaks to a certain area.
__________________
-Jamie
JamieR is offline   Reply With Quote
Old 03-16-2005, 03:09 PM   PM User | #7
Marc84
New to the CF scene

 
Join Date: Mar 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Marc84 is an unknown quantity at this point
Yeah i know. I'm trying to get rid of the <br />'s. I didn't make this layout myself.
If I delete all the <br />'s my site will look like this: http://www.beltonenplaza.com/index2.php Anybody got an idea how to solve this?

And i know i should get rid of all the tables and recode it completely with css. Anybody got some online readings about this?
Marc84 is offline   Reply With Quote
Old 03-16-2005, 05:52 PM   PM User | #8
Marc84
New to the CF scene

 
Join Date: Mar 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Marc84 is an unknown quantity at this point
Allright, I've fixed everything, thanks!
Marc84 is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

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

Forum Jump


All times are GMT +1. The time now is 01:32 PM.


Advertisement
Log in to turn off these ads.