Topic: CSS Centering (Redundancy much?) (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=11150" title="Pages that link to Topic: CSS Centering (Redundancy much?) (Page 1 of 1)" rel="nofollow" >Topic: CSS Centering (Redundancy much?) <span class="small">(Page 1 of 1)</span>\

 
SPyX
Bipolar (III) Inmate

From: College Station, TX
Insane since: Aug 2002

posted posted 02-17-2004 00:13

So it seems like this is the only thing I ever really post here any more. I have this nice simple solution for centering this site. It is the same site I made for this program last year but it used to be aligned left and I decided I should update now that I have a better grasp of CSS. The solution works perfect in IE but Mozilla doesn't like it much.

Any advice you can give would be appreciated.

I suppose I could use the three column holy grail thing and make the outer two columns empty but that might get messy eh?

Edit: Fix link

---------------------------------------
www.bonfirecoalition.com.
---------------------------------------

[This message has been edited by SPyX (edited 02-17-2004).]

poi
Paranoid (IV) Inmate

From: France
Insane since: Jun 2002

posted posted 02-17-2004 01:01

replace the #menu and #container CSS rules by

#menu
{
font-size: 17px;
}
#container
{
}


,and add the following rules in the #body selector

position:absolute;
width: 710px;
left:50%;
margin-left:-305px;
text-align:center; // for IE5.0 and IE5.5



It works in FF0.8 and IE5.0+
Hope that helps.

[edit] Edit CSS rocks [/edit]


[This message has been edited by poi (edited 02-17-2004).]

SPyX
Bipolar (III) Inmate

From: College Station, TX
Insane since: Aug 2002

posted posted 02-17-2004 01:56

Adding the stuff to body worked in mozilla as long as I didn't change the menu and container stuff, but IE isn't picking up the -305px it would seem.

Edit: That method also doesn't work for 800x600.

---------------------------------------
www.bonfirecoalition.com.
---------------------------------------



[This message has been edited by SPyX (edited 02-17-2004).]

poi
Paranoid (IV) Inmate

From: France
Insane since: Jun 2002

posted posted 02-17-2004 03:28

I had forgotten to mention to void the #header selector too.
With(out) this new rule it should work in IE5.01 , IE5.5, IE6.0, MZ1.6 and FF0.8

But you're right it's misaligned in 800x600, and in 1024x768 the left margin is ~195 while it is ~95 on the right Ok, that was surprising to see those little hacks work everywhere in every conditions but the new problem is weird and deserve a little more time to locate and fix it.

SPyX
Bipolar (III) Inmate

From: College Station, TX
Insane since: Aug 2002

posted posted 02-17-2004 03:49

AH! Got it now. If you want to keep tackling this feel free but I believe I can live with it. Honestly I think I am going to stop designing for 600x800 soon anyway.

Thanks for the help!

---------------------------------------
www.bonfirecoalition.com.
---------------------------------------

poi
Paranoid (IV) Inmate

From: France
Insane since: Jun 2002

posted posted 02-17-2004 04:09

How did you fix it ?
Alas there's still many people using 800x600 , most probably because they don't even know/care how to change the resolution.

SPyX
Bipolar (III) Inmate

From: College Station, TX
Insane since: Aug 2002

posted posted 02-17-2004 08:07

I didn't fix it. I decided to live with it.

quote:
Alas there's still many people using 800x600



And there probably will be for many years to come. At some point I think you just have to leave behind those that are. . . well. . . behind. My computer isn't much and I still run at 1024x1280. Since it doesn't mess with those using a small screen size, just those using a small resolution I don't feel too bad. Like I said, if you want to investigate this more feel free, we'll all learn something if you figure it out, but it is beyond me and as far as I am concerned this project is done. For this year anyway.

Cheers!

---------------------------------------
www.bonfirecoalition.com.
---------------------------------------

SPyX
Bipolar (III) Inmate

From: College Station, TX
Insane since: Aug 2002

posted posted 02-17-2004 19:42

::Removes foot from mouth::

Ok, so there IS something that needs to be fixed. Site is "live" here. The table that is generated from groups' bids is allowing its text to be resized even though I specify 12px in the SS. This is the only place this is happening on the site.

---------------------------------------
www.bonfirecoalition.com.
---------------------------------------



Post Reply
 
Your User Name:
Your Password:
Login Options:
 
Your Text:
Loading...
Options:


« BackwardsOnwards »

Show Forum Drop Down Menu