PHP code example of rsr / yii2-button-dropdown-sorter

1. Go to this page and download the library: Download rsr/yii2-button-dropdown-sorter 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/ */

    

rsr / yii2-button-dropdown-sorter example snippets


<?= ListView::widget([
		'dataProvider' => $dataProvider,
		'itemView' => '_views',
		'layout' => "{sorter}\n{summary}\n{items}\n{pager}",
		'sorter' => [
			'class' => 'rsr\yii2\ButtonDropdownSorter',
			'label' => 'Sort Items',
		],
]);