JBE
JBE

Reputation: 12597

overflow:auto not working in FireFox 16

I know there are a lot of post about overflow problem in FF (most for old version) or elsewhere but I can't find something related to my example.

I tried this little piece of code which should produce a scrollbar : it works as expected in Chrome and IE but not in FireFox.

<!DOCTYPE html>

<html><body>
 <div style="height: 25px; overflow: auto;">
   <div style="height: 100px;"></div>
 </div>
</body></html>

Here is an online example : http://jsfiddle.net/v7kqP/5/

​ I am using FireFox 16.0.2. Am I doing something wrong or is it a FF bug ?

Upvotes: 1

Views: 882

Answers (2)

Boris Zbarsky
Boris Zbarsky

Reputation: 35064

Firefox won't show the vertical scrollbar if it thinks there's not enough space to show the whole thing. Clearly it thinks 25 pixels is not enough space to show a vertical scrollbar, in your case...

Upvotes: 0

Chankey Pathak
Chankey Pathak

Reputation: 21666

It's scrollable. Try putting some content.

<!DOCTYPE html>

<html><body>
<div style="height: 25px; overflow: auto; border: 1px solid blue;"><div style="height: 100px; border: 1px solid red;">Here goes the content......................................</div></div>
</body></html>

Demo

Upvotes: 1

Related Questions