width - Display: Inline block - What is that space? -


this question has answer here:

inline blocks have weird space in-between them. live it, point where, if load more content ajax call, tiny space goes away. know i'm missing here.

div {     width: 100px;     height: auto;     border: 1px solid red;     outline: 1px solid blue;     margin: 0;     padding: 0;      display: inline-block; } 

http://jsfiddle.net/awmmt/

how make spacing consistent in inline blocks ?

the space in html. there several possible solutions. best worst:

  1. remove actual space in html (ideally server when file served, or @ least input template spaced appropriately) http://jsfiddle.net/awmmt/2/
  2. use float: left instead of display: inline-block, has undesirable effects on t height: http://jsfiddle.net/awmmt/3/
  3. set container's font-size 0 , set appropriate font-size internal elements: http://jsfiddle.net/awmmt/4/ -- pretty simple, can't take advantage of relative font size rules on internal elements (percentages, em)

Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -