This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Stylesheets > January 2005 > Re: List/menu spacing is browser dependent (argh) - Solved, sort





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Re: List/menu spacing is browser dependent (argh) - Solved, sort
Jim Moe

2005-01-21, 11:17 pm

Jim Moe wrote:
>
> <http://www.sohnen-moe.com/test.html>
>
> The relevant CSS is:
> #menuleft1 { width: 160px;
> margin: 50px 0 0 0; padding: 0; }
> #menuleft1 ul {
> margin: 0 0 0 5px; padding: 0; }
> #menuleft1 li { float: left;
> line-height: 0%;
> list-style: none; }
> #menuleft1 li p { height: 30px; }
>

The CSS became:
#menuleft1 { width: 160px;
margin: 50px 0 0 0; line-height: 0%; padding: 0; }
#menuleft1 ul {
margin: 0 0 0 5px; padding: 0;
font-size: 0; }
#menuleft1 li {
line-height: 0%;
list-style: none; }
#menuleft1 li p {
height: 10px;
line-height: 0%; margin: 0; padding: 0; }

The important change was removing "float:left".
The "font-size:0" fixes an IE problem where it adds extra space below
the baseline for descenders, even though the line-height is zero. This is
a weak solution and would appreciate any alternative.

--
jmm dash list (at) sohnen-moe (dot) com
(Remove .AXSPAMGN for email)
Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews