#1
I created a new app today and ran into this error when setting Records Per Page to 10 under Manage Pages.



The value of that option is zero but it is empty when sent to the set_per_page function.
#2
Hi mjim,

This is a simple fix to the method 'set_per_page' in "Trongate_pages.php'

The type hinting was causing the issue when we had an index of 0. Also, the check for: is not correct as it would set the value of 20 to the index.

The solution is to change the method to this:

Happy coding!
#3
Hi Simon

Thank you for this update!

I still ran into a few issues and realized that $_SESSION['selected_per_page'] needs to be a number from the options array, not the index.

It's working for me now. Here are the two small changes I made:



To fetch the number of records per page it requires the index for those options:
#4
Hey Simon

I added the fix you posted in Github to my Core.php and everything is working fine now without making any changes to Trongate_pages.php.

Thank you!
Jim