467,163 Members | 943 Online
Bytes | Developer Community
Ask Question

Home New Posts Topics Members FAQ

Post your question to a community of 467,163 developers. It's quick & easy.

height attribute in IE 6.0 CSS

Hello everyone and thanks in advance.

I am having a very simple but frustrating problem with IE 6.0. I have
a style defined as:

..tooltip{
background-color:#FFFF99;
font-family: Arial, Helvetica, sans-serif;
font-size: 8pt;
color: black;
border: 1px solid black;
left:100px;
top:200px;
width:100px;
height: 20px;
visibility: visible;
position: absolute;
}
I then use this style in a div: <div id='tooltip1'
class="tooltip"></div>

Changing the height below some value (below about 15px) causes no
further changes to the height of the div in IE 6.0., although it does
work as it should in NS 7.1. I have tried this using both standards
mode and non-standards mode with no effect.

Thanks for any help you can provide,

Sina Tootoonian
Jul 20 '05 #1
  • viewed: 3070
Share:
2 Replies
Els
Sina Tootoonian wrote:
Hello everyone and thanks in advance.

I am having a very simple but frustrating problem with IE 6.0. I have
a style defined as:

.tooltip{
background-color:#FFFF99;
font-family: Arial, Helvetica, sans-serif;
font-size: 8pt;
color: black;
border: 1px solid black;
left:100px;
top:200px;
width:100px;
height: 20px;
visibility: visible;
position: absolute;
}
I then use this style in a div: <div id='tooltip1'
class="tooltip"></div>

Changing the height below some value (below about 15px) causes no
further changes to the height of the div in IE 6.0., although it does
work as it should in NS 7.1. I have tried this using both standards
mode and non-standards mode with no effect.


IE just makes the div fit around its content. So I suppose
your content is higher than 15px.
What's in it? If it's just a word or two, not wrapping
lines, try setting the line-height to less than 15px, and
also the padding of the div to zero, and the margin of
whatever is inside that div to zero as well.
What happens then?

--
Els
http://locusmeus.com/
Sonhos vem. Sonhos vão. O resto é imperfeito.
- Renato Russo -

Jul 20 '05 #2
On 4 May 2004 15:11:00 -0700, Sina Tootoonian
<ac**************@hotmail.com> wrote:
Hello everyone and thanks in advance.

I am having a very simple but frustrating problem with IE 6.0. I have
a style defined as:

.tooltip{
background-color:#FFFF99;
font-family: Arial, Helvetica, sans-serif;
font-size: 8pt;
color: black;
border: 1px solid black;
left:100px;
top:200px;
width:100px;
height: 20px;
visibility: visible;
position: absolute;
}
I then use this style in a div: <div id='tooltip1'
class="tooltip"></div>
As you never set an id tooltip1, no need to include this. If you did,
you've left out critical info. If so, post a URL where we can see all
that's going on.
Changing the height below some value (below about 15px) causes no
further changes to the height of the div in IE 6.0., although it does
work as it should in NS 7.1. I have tried this using both standards
mode and non-standards mode with no effect.


My guess is this is IE's overflow default. IE will stretch the container
to accomodate content, while other browsers might simply allow content to
overflow the visible borders. Might be that even though no content is
there, the 1em of height (which will be about 15px in many cases) is
accounted for even if you want it smaller.

BTW, why did you set font-size in pt? Use ems or %. IE cannot scale text
unless you do that, making it impossible for some users to read your
content.

Jul 20 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

6 posts views Thread by stevehayter | last post: by
17 posts views Thread by Torbjørn Pettersen | last post: by
9 posts views Thread by Wladimir Borsov | last post: by
3 posts views Thread by Lamberti Fabrizio | last post: by
7 posts views Thread by simon | last post: by
6 posts views Thread by jslaybaugh@gmail.com | last post: by
19 posts views Thread by Rabel | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.