We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 4172
    • 5,888 Posts
    seems, you have furls off
    try to change this part of the snippet to:

    $url=$modx->makeUrl($ajaxpage);
    $furls = $modx->getOption('friendly_urls');
    $qstring = !empty($furls) ? '?page=' : '&page=';
    $js="
    <script>
    $(document).ready(function() {
    new Paginator('{$url}',{qString : '{$qstring}'});
    }); 
    </script>
    ";
    $modx->regClientStartupHTMLBlock($js);
    
      -------------------------------

      you can buy me a beer, if you like MIGX

      http://webcmsolutions.de/migx.html

      Thanks!
    • I did this simply with only jQuery by adding the following to the ajax page with getList on it:
      	$("ul.pagination a").click(function(event) {
      	  event.preventDefault();
      	  var clicked = $(this).attr("href");
      	  $.get( clicked, function( data ) {
      	    $( "#container" ).html(data);
      	  });
      	});
      
        • 43864
        • 151 Posts
        This is a rather old topic, but you never know if somebody needs it, so here's my contribution:

        I don't use getPage for pagination, I use getResources with a limit of 0 in combination with the plugin MixItUp. Also with this combination some powerful filtering and sorting is possible.

        Remark: MixItUp is not free for commercial use.
          • 33991
          • 65 Posts
          pdoPage has built-in ajax pagination - https://youtu.be/pVVol-gCiv4?t=2m