unwanted space between li elements in IE

This is a discussion on "unwanted space between li elements in IE" within the Web Page Design section. This forum, and the thread "unwanted space between li elements in IE are both part of the Design Your Website category.



Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices


Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old Nov 1st, 2005, 19:06
New Member
Join Date: Nov 2005
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
unwanted space between li elements in IE

hi,

i am having a bit of difficulty with a basic CSS problem which totally ruins my layout :/

I am using an unordered list as a menu and i am using this CSS rules for it:

Code: Select all
ul{ 
font-family: tahoma; 
font-size: 10px; 
letter-spacing: 1pt;
list-style-type: none;
}
 
li{
text-align: right; 
}
quite basic formatting, but the problem i am having is it looks different on IE and FF. i get unwanted space between two list elements, please check the attached screenshot below.


i tried using padding:0px and margin: 0px but it didnt help.

how can i get rid of the unwanted space in IE ( so that it looks like the firefox screenshot) ?

thanks.
Attached Images
File Type: png ulspacingie4kq.png (16.6 KB, 141 views)

Last edited by Rob; Nov 2nd, 2005 at 22:43.
Reply With Quote

  #2 (permalink)  
Old Nov 1st, 2005, 21:53
New Member
Join Date: Nov 2005
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Re: unwanted space between li elements in IE

the problem is solved.

please check this link if you suffer from the same thing

regards.
Reply With Quote
  #3 (permalink)  
Old Nov 2nd, 2005, 13:07
Banned Member
Join Date: Sep 2005
Posts: 51
Thanks: 0
Thanked 0 Times in 0 Posts
Re: unwanted space between li elements in IE

li{display:inline}
the web "gurus" kall this a "hack".
its 1 wae tu get rid av xtra carriag-reterns IE add sumtimes.
Reply With Quote
  #4 (permalink)  
Old Nov 7th, 2005, 13:14
New Member
Join Date: Jul 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Re: unwanted space between li elements in IE

Setting display: inline; solves the symptom but not the accuall problem, you also enter another problem since you change the behaviour of the list by making every element inline instead of blocks. Problem is that IE is "padding" each element with a certain height from the font-size.

An example of this is trying to create a <div> which is 1px in height, you will have huge problems acomplishing this in IE, though Firefox displays it 1px without any problems.

Since you have set your font-size to 10px, you can also set the line-height to 10px and the problem is solved.

Mvh,
Kim Steinhaug
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
www.steinhaug.no - www.easywebshop.no - www.easycms.no
Reply With Quote
Reply

Tags
unwanted, space, between, elements

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
unwanted space between 2 images Craigj1303 Web Page Design 1 Apr 6th, 2008 12:04
unwanted horizontal scroll mykl Web Page Design 11 Sep 30th, 2007 02:05
unwanted space under image in IE Craigj1303 Web Page Design 2 Sep 5th, 2007 20:47
PHP XML Counting Elements Don Logan PHP Forum 1 Mar 18th, 2006 03:03
Unwanted gap under navbar in IE6 for windows Treo Web Page Design 13 Mar 8th, 2006 12:34


All times are GMT. The time now is 02:26.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs 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 43