drt5813 2015-02-26 06:32
浏览 5

Yii CLinkPager分为2组分页

I am new to YII frame work

I have integrated the pagination by refer this url Click here

I used the complex way method(By refer the above url) to integrate the pagination. It is working fine. But I didn't use 2 pagination in single page. the page variables overlapped.

I need to list members and retailers separately. 2 sections are collaid with the same page variables.

To override the page variable I tried to use pageVar parameter. But it shows an error.

I don't know how to overwrite the page variables

Pagination Code for members:

        $this->widget(
    'CLinkPager', array(
        'currentPage'=>$pages->getCurrentPage(),
        'itemCount'=>$item_count,
        'pageSize'=>$page_size,
        'firstPageLabel' => '',
        'prevPageLabel' => '',
        'nextPageLabel'=>'',
        'lastPageLabel'=>'last',
        'header'=>'<p>Page :</p>',
    'htmlOptions'=>array('class'=>'pages'),
    ));



Pagination Code for Retailers:

        $this->widget(
    'CLinkPager', array(
        'currentPage'=>$pages_ret->getCurrentPage(),
        'itemCount'=>$item_count2,
        'pageSize'=>$page_size2,
        'firstPageLabel' => '',
        'prevPageLabel' => '',
        'nextPageLabel'=>'',
        'lastPageLabel'=>'last',
        'header'=>'<p>Page :</p>',
    'htmlOptions'=>array('class'=>'pages'),
    ));

Please give a solution. Thanks

  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥15 华为ensp模拟器中S5700交换机在配置过程中老是反复重启
    • ¥15 java写代码遇到问题,求帮助
    • ¥15 uniapp uview http 如何实现统一的请求异常信息提示?
    • ¥15 有了解d3和topogram.js库的吗?有偿请教
    • ¥100 任意维数的K均值聚类
    • ¥15 stamps做sbas-insar,时序沉降图怎么画
    • ¥15 买了个传感器,根据商家发的代码和步骤使用但是代码报错了不会改,有没有人可以看看
    • ¥15 关于#Java#的问题,如何解决?
    • ¥15 加热介质是液体,换热器壳侧导热系数和总的导热系数怎么算
    • ¥100 嵌入式系统基于PIC16F882和热敏电阻的数字温度计