PHP code example of lg-xenos / yii2-banner-system

1. Go to this page and download the library: Download lg-xenos/yii2-banner-system 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/ */

    

lg-xenos / yii2-banner-system example snippets


	/* ... */
	'bootstrap'           => [ /* ... */ 'adwert' /* ... */ ],
	/* ... */
	'modules'             => [
		/* ... */
		'adwert'   => [
			'class'          => lgxenos\yii2\banner\BannerModule::class,
			'frontPrettyUrl' => '/asd/',
            //
			// ОПЦИОНАЛЬНЫЕ НАСТРОЙКИ. ТОЛЬКО ЕСЛИ ВАМ НАДО ЧТО-ТО МЕНЯТЬ
            // module settings
			'uploadPath'     => '@frontend/upload/banners/%USER_ID%/',
			'uploadWebPath'  => '/upload/banners/%USER_ID%/',
			'userModel'      => \common\models\User::class,
			'userModelName'  => 'username',
			'mobileWidth'    => 768,
			// yii settings
			'layout'         => '@frontend/modules/yiiAdmin/views/layouts/main.php',
		],
		/* ... */
	],

	/* ... */
	'bootstrap'           => [ /* ... */ 'adwert' /* ... */ ],
	/* ... */
	'modules'             => [
		/* ... */
		'adwert'   => [
			'class'          => lgxenos\yii2\banner\BannerModule::class,
			'frontPrettyUrl' => '/asd/',
            //
			// OPTIONAL SETTINGS. IF YOU NEED CHANGE SOMETHING ONLY
            // module settings
			'uploadPath'     => '@frontend/upload/banners/%USER_ID%/',
			'uploadWebPath'  => '/upload/banners/%USER_ID%/',
			'userModel'      => \common\models\User::class,
			'userModelName'  => 'username',
			'mobileWidth'    => 768,
			// yii settings
			'layout'         => '@frontend/modules/yiiAdmin/views/layouts/main.php',
		],
		/* ... */
	],