Alphapager demo

Showing 41-60 of 611 items.
#Last NameFirst NameBornDied
41BergmanIngmar1918/07/142007/07/30
42BerlageHendrik Petrus1856/02/211934/08/12
43BerryChuck1926/10/182017/03/18
44BertolucciBernardo1940/03/162018/11/26
45BeuysJoseph1921/05/121986/01/23
46Björk1965/11/21
47BlakeWilliam1757/11/281827/08/12
48BlakeyArt1919/10/111990/10/16
49BlankBoris1952/01/15
50BogartHumphrey1899/01/231957/01/14
51BohrNiels1885/10/071962/11/18
52BöllHeinrich1917/12/211985/07/16
53Bono1960/05/10
54BooleGeorge1815/11/021864/12/08
55BorchertWolfgang1921/05/201947/11/20
56BorgesJorge Luis1899/08/241986/06/14
57BowieDavid1947/01/082016/01/10
58BraccoLorraine1954/10/02
59BrandauerKlaus Maria1943/06/22
60BrandoMarlon1924/04/032004/07/01

Yii2 Alphapager lets you do alphabetic paging in the Yii framework 2.0. On this page it is shown in it's default operation, 'out of the box'.

The relevant code involved is something like this:

<?php

use sjaakp\alphapager\ActiveDataProvider;
use sjaakp\alphapager\AlphaPager;

$query = Person::find()->orderBy('last_name, first_name');

$dataProvider = new ActiveDataProvider([
    'query' => $query,
    'alphaAttribute' => 'last_name',
]);
?>

<?= AlphaPager::widget([
    'dataProvider' => $dataProvider,
]) ?>

<?= GridView::widget([
    'dataProvider' => $dataProvider,
    'columns' => [
        ['class' => 'yii\grid\SerialColumn'],

        'last_name:ntext',
        'first_name:ntext',
        'born:date',
        'died:date',
    ],
]); ?>

A slightly more advanced example is here.