如何更改css以进行分页? 我有代码:
echo LinkPager::widget([
'pagination' => $pages,
'activePageCssClass'=>'act',
]);
并在我的CSS中扮演课程:
.act{
color:red;
}
但它不起作用。 我必须为它写什么选择?
答案 0 :(得分:4)
这是Pagination的完整配置
<?php
LinkPager::widget([
'pagination' => $pages,
//Css option for container
'options' => ['class' => ''],
//First option value
'firstPageLabel' => ' ',
//Last option value
'lastPageLabel' => ' ',
//Previous option value
'prevPageLabel' => ' ',
//Next option value
'nextPageLabel' => ' ',
//Current Active option value
'activePageCssClass' => 'p-active',
//Max count of allowed options
'maxButtonCount' => 8,
// Css for each options. Links
'linkOptions' => ['class' => ''],
'disabledPageCssClass' => 'disabled',
// Customzing CSS class for navigating link
'prevPageCssClass' => 'p-back',
'nextPageCssClass' => 'p-next',
'firstPageCssClass' => 'p-first',
'lastPageCssClass' => 'p-last',
]);