473,373 Members | 1,179 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,373 software developers and data experts.

1px bottom gap with unordered list (firefox 2.0.0.9)

Hi all,

I have a problem with the following _simple_ markup/css. Firefox
(2.0.0.9) renders a one pixel gab underneath the li/a tags. It seems
as if Firefox expands the ul element for that reason.
IE7 and Opera 9.24 have no problems with that.

Any idea how to solve this problem?

thx a lot

Juergen

--- doctype ---

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://
www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
--- here the style ---
<style>
#masthead{ background: blue; margin:0 ; padding:0 ; }
#masthead ul { list-style:none ; margin:0 ; padding:0 ; text-align:
center;background: red;}
#masthead li { display:inline; background: yellow;}
#masthead a:link,
#masthead a:visited { background: green; text-decoration:none;}
</style>

--- here the markup ---

<div id="masthead">
<ul>
<li><a href='#'><span class='l14'>LADEN</span></a></li>
<li><a href='#'><span class='l15'>EVENTS</span></a></li>
</ul>
</div>
Nov 19 '07 #1
2 2243
In article
<b9**********************************@f13g2000hsa. googlegroups.co
m>,
JuergenRiemer <ju************@gmail.comwrote:
Hi all,

I have a problem with the following _simple_ markup/css. Firefox
(2.0.0.9) renders a one pixel gab underneath the li/a tags. It seems
as if Firefox expands the ul element for that reason.
IE7 and Opera 9.24 have no problems with that.

Any idea how to solve this problem?
Take a look at the essentials (simpler than your markup and css
but shows the "pixel-perfection" problem you perceive. Different
browsers assign slightly different line height instructions. So
fiddle about with the line height at:

http://netweaver.com.au/alt/juergen.html

I have made your containing div have a function (to exhibit its
background) whereas in your code it was not clear what it was
there for. Your spans were not obviously functional either. But
try the above to give you a lead.

Without a line height instruction by the author, different
browsers give quite a few different results. Anyway, play about
and tell me what you decide.

--
dorayme
Nov 19 '07 #2
On 19 Nov., 22:59, dorayme <doraymeRidT...@optusnet.com.auwrote:
In article
<b9c6bd1f-d8bb-4beb-a822-484f10e6d...@f13g2000hsa.googlegroups.co
m>,
[..]
http://netweaver.com.au/alt/juergen.html

Without a line height instruction by the author, different
browsers give quite a few different results. Anyway, play about
and tell me what you decide.
dorayme,

thanks for your hint concerning the line-height attribute.
my tabs now work like a charm!!
thank you a lot!

Juergen

Nov 19 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

19
by: A.Translator | last post by:
I have an unordered list as menu and want some space at the bottom, underneath the last <li>. I have tried: setting bottom-margin to ul setting bottom-margin to containing <div> setting padding...
0
by: Steve Dorsey | last post by:
Hello I'm creating an unordered list which will be used as a nav element on my page. I am using the following CSS: #nav { position:relative; left:10px;
1
by: Edward | last post by:
I created a simple CSS layout (code and example below) for bloggin/writing but ran into five issues that I need help with: 1. How do I get rid of the right-margin red line on the last three...
3
by: laredotornado | last post by:
Hi, On both Firefox and IE, how can I replace the bullets before unordered list items, with double arrows ">>" throughout my site? Thanks, - Dave
1
by: laredotornado | last post by:
Hi, Is there a cross-browser way to keep the items of an unordered list on the same line (horizontal plane)? This is the code I'm working with <ul class="tabs-nav"> <li class=""...
4
by: knkk | last post by:
Hi, I need to be able to reduce the default space between a bullet and the text that follows it. After searching all and sundry, I came up with the following CSS, that unfortunately does not work...
2
by: webhead | last post by:
I have a website at This Link which contains some unordered lists at the right. The news headlines list has the first item appearing normally, but all the other items are pushed over to the right....
7
by: GTalbot | last post by:
Hello fellow authoring.stylesheets colleagues, Can someone please explain why the bottom margin of the last inflow block-level child in an overflowed parent should not have its margin reachable....
2
by: asc4john | last post by:
When including an unordered list in an unordered list: Should it be included as a "list" item as in: <ul><liitem</ li><ul.... </ul<liitem</li</ul> or included in the LI element as in:...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.