2013-04-05, 03:40 AM
2013-04-07, 09:06 PM
<script type="text/javascript">
jQuery(function($) {
$.ias({
container : '.looksthreads',
item : '.item',
pagination : '.pagination',
next : 'a.pagination_next',
loader : '<img src="/images/spinner.gif">',
onLoadItems: function(items) {
// hide new items while they are loading
var $newElems = $(items).show().css({ opacity: 0 });
// ensure that images load before adding to masonry layout
$newElems.imagesLoaded(function(){
// show elems now they're ready
$newElems.animate({ opacity: 1 });
$('.listing').masonry( 'appended', $newElems, true );
});
return true;
}
});
});
</script>
Is there something wrong with the syntax here? Also, I have no idea what's supposed to go where .listing is.
2013-04-07, 09:44 PM
I believe .looksthreads is what would go where .listing is.
2013-04-07, 10:07 PM
OK, thanks. I'll try that. But syntax is stopping the script from running at this point ...
2013-04-07, 11:31 PM
or I may have read that wrong
2013-04-11, 03:46 PM
Bump >>;
2013-04-12, 10:05 PM
Hm, your syntax appears to be fine (my code editor thinks so too xD).
Any chance you could post the error you're getting?
Any chance you could post the error you're getting?
2013-04-13, 10:22 AM
(2013-04-07, 09:06 PM)brad-t Wrote: [ -> ]Also, I have no idea what's supposed to go where .listing is.
I think you might want .looksthreads (or your container) there, judging by context and choice of default name.
2013-04-13, 06:42 PM
No error, it just stops executing. Here's the sample from Ajax scrolling github page:
jQuery.ias({
container : '.listing',
item: '.post',
pagination: '#content .navigation',
next: '.next-posts a',
loader: '<img src="images/loader.gif"/>',
onLoadItems: function(items) {
// hide new items while they are loading
var $newElems = $(items).show().css({ opacity: 0 });
// ensure that images load before adding to masonry layout
$newElems.imagesLoaded(function(){
// show elems now they're ready
$newElems.animate({ opacity: 1 });
$('.listing').masonry( 'appended', $newElems, true );
});
return true;
}
});
2013-04-20, 02:09 AM
Anyone willing to give this a shot on my site? This is really holding me up.