css - Inline block adding extra space in firefox -


i have webpage have stacked div's inline-block properties. however, adds spacing between 2 div's in firefox. design consistent in safari , chrome.

here's sample fiddle that.

#main {     display: block; } #sub11, #sub12, #sub21, #sub22,  #sub31, #sub32 {     display: inline-block;     background:red;     padding:0;     //margin-right:-4px;     margin-top:3px;     margin-bottom:3px; } 

firefox adds space betweeb ghi , try row, while abc , ghi consistent other rows comes after try.

the code:

 display: inline-block; 

will display spaces, have add float them appear directly after 1 another.

try adding a:

float:left;  

to #sub11, etc..


Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -