PHP code example of skeeks / cms-shop-cart-items-widget

1. Go to this page and download the library: Download skeeks/cms-shop-cart-items-widget library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

skeeks / cms-shop-cart-items-widget example snippets



<?= \skeeks\cms\shopCartItemsWidget\ShopCartItemsListWidget::widget([
    'dataProvider' => new \yii\data\ActiveDataProvider([
        'query' => \Yii::$app->shop->shopFuser->getShopBaskets(),
        'pagination' =>
        [
            'defaultPageSize' => 100,
            'pageSizeLimit' => [1, 100],
        ]
    ]),
    //'headerView' => '@app/view/.../header',
    //'footerView' => '@app/view/.../footer',
    //'itemView' => '@app/view/.../item',
]); 


<?= \skeeks\cms\shopCartItemsWidget\ShopCartItemsListWidget::widget([
    'dataProvider' => new \yii\data\ActiveDataProvider([
        'query' => $model->getShopBaskets(),
        'pagination' =>
        [
            'defaultPageSize' => 100,
            'pageSizeLimit' => [1, 100],
        ],
    ]),
]); 


<?= \skeeks\cms\shopCartItemsWidget\ShopCartItemsListWidget::widget([
    'dataProvider' => new \yii\data\ActiveDataProvider([
        'query' => $model->getShopBaskets(),
        'pagination' =>
        [
            'defaultPageSize' => 100,
            'pageSizeLimit' => [1, 100],
        ],
    ]),
    'footerView'    => false,
    'itemView'      => '@skeeks/cms/shopCartItemsWidget/views/items-list-order-item',
]);