Posted by dorayme on 06/19/06 05:38
CSS:
ul {margin:0;padding:0;}
li {list-style-type:none;margin:0;padding:0;display:inline;}
HTML:
<ul>
<li>Item1</li>
<li>Item2</li>
<li>Item3</li>
</ul>
There is, naturally a space between the text of the links. Could
someone please remind me how to find out how many ems this is in
any particular browser without trial and error, given no more
than the above css and html. How standard is this space among
browsers? Or is it too browser dependent?
I can get this in Safari:
Item1Item2Item3
by
li {
margin-left: -0.2em;
margin-right: -0.2em;
}
Not that I want to end up removing the space! I am thinking about
this to better control something a bit more complicated to do
with borders and inline lists. I have a guess solution which
works not bad on my browsers, but be nice to know any deeper
answer to above. I get hazy about the issue ;-)... the exact
"whereabouts" or any space reserved or fossilized for the missing
list item marker and other things has always slightly puzzled
me...
--
dorayme
Navigation:
[Reply to this message]
|