This is an old revision of the document!


Infinite Ajax Scroll (IAS)

Author:adamderesz http://forum.phpwcms.org/viewtopic.php?f=1&t=24285

Soo, tried it on phpwcms 1.5.4.1 (r491), and it worked (in general) straight from the box. Code used was Infinite Ajax Scroll (IAS) from https://github.com/webcreate/infinite-ajax-scroll

Here's how it went:

Follow these simple steps an you'll get it!

Step 1

Site is using paginate code as in config/phpwcms/conf.template_default.inc.php file with added extra class for “next page' link as it's required by the IAS script to work

Line 122:
$template_default['article_paginate_navi']   = '<div class="paginate paginate-{POS}">{PREV:&laquo;} <span class="page-next">{NEXT:&raquo;}</span> page # of ##</div>'; //

Step 2

I have the 'articles' template set, that is different to all others within the site for various reasons, and it includes jQuery (v1.7), the IAS script and then call to start IAS. Theres' some small css provided with IAS I just placed together with my main css file. It's just to position the loading progress graphic, mainly and make nice notes (IAS script can add notes like 'no more to view' or 'hover here for more content') - I don't use that here. The call for that lot is also straight from the box:

<script type="text/javascript">
jQuery.ias({
    container : '#cnt',
    item: '.artlistentry',
    pagination: '#cnt .paginate',
    next: '.page-next a',
    loader: '<img src="/img/loader.gif"/>'
});
</script>

Step 3

english/other-enhancements/infinite_scolling.1389446182.txt.gz · Last modified: 2018/06/03 18:08 (external edit)
www.planmatrix.de www.chimeric.de Creative Commons License Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0