I wrote a script that shows articles. I added to it pagination.
However, I have one question: whether it is something to do with the parameters for subsequent pages.
So as have a look after the change
The controller use
$dataProvider = new ActiveDataProvider([ 'query' => AppPages::find()->where(['category_id' => $_GET['id']] ->orderby('page_id DESC'), 'pagination' => [ 'pageSize' => 10, ] ]); $PageContent = $dataProvider->getModels();
While in view of:
echo LinkPager :: widget ([ 'pagination' => $dataProvider->pagination, ]);