1

I'm using the answers from this question. When I create a static page, it works great, but when I use jquery append to create each box, it doesn't work. Each item ends up directly next to each other.

The jsFiddle that works and the modified jsfiddle that doesn't work. What would cause this to not work? How can I fix it or work around it?

Community
  • 1
  • 1
xdumaine
  • 10,096
  • 6
  • 62
  • 103
  • 1
    The answer I gave in that question can unfortunately be very picky about whitespace. Make sure that you test in Safari, it sometimes gets this wrong in a unique way. – thirtydot Jan 23 '12 at 09:58

1 Answers1

1

Try this

$(function() {
    for(var i=0;i<10;i++){
        $('#container').append('<div></div>\n');
    }
})

Demo

ShankarSangoli
  • 69,612
  • 13
  • 93
  • 124