Give help. Get help.

  • # March 24, 2013 at 7:27 am

    This is the code:

    < .div>
    < .div id="a" style="height:100px;">1
    < .div id="a" style="height:150px;">2
    < .div id="a" style="height:100px;">3
    < .div id="a" style="height:150px;">4
    < .div id="a" style="height:100px;">5
    < .div id="a" style="height:150px;">6
    < .div id="a" style="height:100px;">7
    < .div id="a" style="height:150px;">8

    What i want is for the div’s to occupy the spaces below each divs. like in this site:

    can css handle it or maybe add some javascript?
    Please help.

    # March 24, 2013 at 7:37 am

    Remove the periods before the divs. That markup is invalid as is. Also, it would benefit you if you just created a stylesheet and put your CSS in that. Don’t use inline styling. It’s a hassle.

    Take a look at masonry.js

    # March 24, 2013 at 7:40 am

    i did it on purpose because the code wont preview here. Just take the periods and it’ll generate.

    # March 24, 2013 at 7:43 am

    Thanks Chirs! this is what im looking for :)

    # March 24, 2013 at 7:46 am

    jQuery Isotope is another good masonry type script to take a look at

    # March 24, 2013 at 7:48 am

    Thanks Chris and Pooders. Learned something new again :).

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.