View Full Version : [CODE] Help with HTML Code

Feb 24th, 2012, 06:20 AM
So I was on Tumblr. And I entered a code for jMasonry and Infinite Scrolling. But the Infinite Scrolling portion doesn't seem to work.

This is the code I'm using:

<script type="text/javascript" src="http://static.tumblr.com/dbek3sy/iBElrgjim/jquerymasonry.js"></script>
<script type="text/javascript" src="http://static.tumblr.com/dbek3sy/Qyblrgjfn/jqueryinfintescroll.js"></script>

<script type="text/javascript">
$(window).load(function () {
var $content = $('#posts');
$content.masonry({itemSelector: '.entry'}),
navSelector : 'div#pagination',
nextSelector : 'div#pagination a#nextPage',
itemSelector : '.entry',
loading: {
finishedMsg: '',
img: 'http://static.tumblr.com/dbek3sy/pX1lrx8xv/ajax-loader.gif'
bufferPx : 600,
debug : false,
// call masonry as a callback.
function( newElements ) {
var $newElems = $( newElements );
// ensure that images load before adding to masonry layout
$content.masonry( 'appended', $newElems, true, function(){$newElems.fadeIn(300);} );



Did I do something wrong?

Feb 24th, 2012, 07:16 AM

This belongs in the JavaScript part of the forums.