Well this script at this point cannot tell that
http://yourdomain.com and
http://www.yourdomain.com are the same site, it has something to do with cookies I believe. You usually get a problem if you access your site using
http://yourdomain.com, since the pagination script is configured to work with the latter.
So its quite simple to fix the problem, use
http://www.yourdomain.com and stick to it. Never forget to write 'www', although it can be a pain for your users who prefer the shorter url without www.