By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,723 Members | 1,655 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,723 IT Pros & Developers. It's quick & easy.

height attribute in IE 6.0 CSS

P: n/a
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
Share this Question
Share on Google+
2 Replies


P: n/a
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 vo. O resto imperfeito.
- Renato Russo -

Jul 20 '05 #2

P: n/a
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.