Jump to content

IE problem, why the additional spaces ?


Rommeo

Recommended Posts

There is additional spaces ( gaps ) in my left menu.

if you check the picture;

zvdc15.jpg

http://tinypic.com/r/zvdc15/4

There is a space between hotels & beaches & Education.

 

Can you please help me to clear these spaces ?. I want it to be look like firefox when I m running it on internet explorer.

 

Thanks.

my css :

#button {
width: 175px;
padding: 0;
font-family: Geneva, Arial, Helvetica, sans-serif;
font-size : 12px;
background-color: #FFFFFF;
color: #333;
font-weight: bold;
margin: 0px;
}

#button ul {
list-style: none;
margin: 0;
padding: 0;
border: none;
width: 175px;


}

#button li {
border-bottom: 1px solid #90bade;
margin: 0;
list-style: none;
list-style-image: none;
padding: 0px;


}
#button img {
border: 0px;
}

#button li a {
display: block;
padding: 5px 5px 5px 0.5em;
border-left: 10px solid #1958b7;
border-right: 10px solid #508fc4;
background-color: #3366cc;
color: #fff;
text-decoration: none;
width: 100%;
}

html>body #button li a {
width: auto;
}

#button li a:hover {
border-left: 10px solid #1c64d1;
border-right: 10px solid #5ba3e0;
background-color: #2586d7;
color: #fff;

}

#button li #active {
border-left: 10px solid #1c64d1;
border-right: 10px solid #5ba3e0;
background-color: #2586d7;
color: #fff;
}
.leftmenusmall {
font-size: 10px;
margin: 0px;
padding: 0px;	
list-style: none;
list-style-image: none;
}

My html :

<body>
<div id="button">
<ul>
<li><a href="Home.html">Tourism</a></li>
<li class="leftmenusmall"><a href="Home.html">Hotels</a></li>
<li class="leftmenusmall"><a href="Home.html">Beaches</a></li>
<li><a href="Home.html">Education</a></li>
</ul>
</div>  
</body>

Link to comment
Share on other sites

Well I would first try some different doctypes because im thinking that ie is going into quirks mode and thats causing you the issue.  However if you cant get one that works.

 

Maybe try

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"
		"http://www.w3.org/TR/REC-html40/strict.dtd">
<html>

 

Seeing as your code appears correct I checked it against the A List Apart article for that code. You shouldnt have to mess with more of the CSS however if you do then you will just have to compensate by adjusting the padding of the elements with the smaller font.

 

Also take a look at this version of that menu.

http://css.maxdesign.com.au/listamatic/vertical10.htm

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.