Welcome Guest, Not a member yet? Register   Sign In
Using the built-in pagination functions

The Model::paginate() method uses the Model and QueryBuilder methods to retrieve data.
PHP Code:
$model = new \App\Models\UserModel();
$model->paginate(10); // calls inside $model->findAll(10); 
To add selection criteria
PHP Code:

You can move the conditions to a separate method.
PHP Code:
public function myConditions($a)


Using $this->db->query() immediately executes the query and cannot be used with the Model::paginate() method.

Messages In This Thread
RE: Using the built-in pagination functions - by iRedds - 01-20-2022, 07:38 AM

Theme © iAndrew 2016 - Forum software by © MyBB