dirname(__FILE__) . DIRECTORY_SEPARATOR . '..', 'name' => 'Auto-Life', 'language' => 'ru', // preloading 'log' component 'preload' => array('log'), // autoloading model and component classes 'import' => array( 'application.models.*', 'application.components.*', 'vendor.z_bodya.yii-i18d-gallery-manager.*', 'vendor.z_bodya.yii-i18d-gallery-manager.models.*', 'vendor.z_bodya.yii-multiselect.*', 'vendor.z_bodya.yii-chosen.*', 'vendor.z_bodya.yii-swiftmailer.*', 'vendor.z_bodya.yii-tinymce.*', 'vendor.z_bodya.yii-elfinder.*', 'vendor.z_bodya.yii-image.*', 'vendor.z_bodya.yii-fileimagearbehavior.*', ), 'modules' => array( // uncomment the following to enable the Gii tool 'gii' => array( 'class' => 'system.gii.GiiModule', 'password' => 'co4rymew', // If removed, Gii defaults to localhost only. Edit carefully to taste. 'ipFilters' => array('127.0.0.1', '::1'), 'generatorPaths' => array( 'application.modules.admin.gii', // a path alias ), ), 'admin', ), // application components 'components' => array( 'swiftMailer' => require('mailer.php'), 'request'=>array( 'enableCsrfValidation'=>false, ), 'messages' => array( 'class' => 'CDbMessageSource', 'language' => 'ru', ), 'assetManager' => array( //'linkAssets' => true, ), 'widgetFactory' => array( 'class' => 'CWidgetFactory', 'widgets' => array( 'TinyMce' => array( 'compressorRoute' => 'admin/tinyMce/compressor', 'spellcheckerRoute' => 'admin/tinyMce/spellchecker', 'fileManager' => array( 'class' => 'TinyMceElFinder', 'connectorRoute' => 'admin/elfinder/connector', ), 'settings' => array( 'content_css' => '/wysiwyg/wysiwyg.css', 'template_external_list_url' => '/wysiwyg/templates.js', ), ), 'GalleryManager' => array( 'controllerRoute' => '/admin/gallery', ), 'ServerFileInput' => array( 'connectorRoute' => 'admin/elfinder/connector', ), 'ElFinderWidget' => array( 'connectorRoute' => 'admin/elfinder/connector', ), ) ), 'image' => array( 'class' => 'vendor.z_bodya.yii-image.CImageComponent', // GD or ImageMagick 'driver' => 'GD', // ImageMagick setup path 'params' => array('directory' => '/opt/local/bin'), ), 'user' => array( // enable cookie-based authentication 'allowAutoLogin' => true, ), // uncomment the following to enable URLs in path-format 'urlManager' => array( 'urlFormat' => 'path', 'showScriptName' => false, 'class' => 'UrlManager', 'rules' => array( // admin module 'admin' => array('admin', 'params' => array('defaultParams' => 'ru')), 'admin/' => array('admin/', 'defaultParams' => array('lang' => 'ru')), 'admin//' => array('admin//', 'defaultParams' => array('lang' => 'ru')), //site links 'sitemap.xml' => 'site/siteMap', "/" => 'site/index', "/error" => 'site/error', "/contact" => 'site/contact', // "/reviews" => 'site/reviews', "/feed" => 'site/feed', //about section links // "/about" => 'about/index', // "/partners" => 'about/partners', // "/partners/" => 'about/partner', // "/jobs" => 'about/jobs', // "/jobs/" => 'about/job', // "/about" => 'about/index', // "/about/partners" => 'about/partners', // "/about/partners/" => 'about/partner', // "/about/jobs" => 'about/jobs', // "/about/jobs/" => 'about/job', //tuning section links // "/tuning" => 'tuning/index', // "/tuning/services/" => 'tuning/service', // "/tuning/" => 'tuning/brand', // "/tuning//" => 'tuning/model', // "/tuning///" => 'tuning/view', //work section links // "/work" => 'work/index', // "/work/" => 'work/brand', // "/work//" => 'work/model', // "/work///" => 'work/view', //service section "/service" => 'service/index', "/service/" => 'service/category', "/service//" => 'service/view', "/service-center/" => 'service/center', //news section // "/news" => 'news/index', // "/feed" => 'news/feed', // "/news-categories/" => 'news/category', // "/show/" => 'news/show', // "/news/" => 'news/view', // "/publications/" => 'news/publications', // "/publication/" => 'news/publication', //action section "/action" => 'action/index', "/action/finished" => 'action/finished', "/action/" => 'action/category', "/action//" => 'action/view', "/stoFilter" => 'stoFilter/index', "/stoFilter/finished" => 'stoFilter/finished', "/stoFilter/" => 'stoFilter/category', "/stoFilter//" => 'stoFilter/view', //auto-sport section // "/sport" => 'sport/index', // "/sport/study" => 'sport/study', // "/sport/awards" => 'sport/awards', // "/sport/team" => 'sport/team', // "/sport/calendar" => 'sport/calendar', // "/sport/albums" => 'sport/albums', // "/sport/album/" => 'sport/album', array( 'class' => 'NodeUrlRule', 'langVar' => 'lang', 'langExpression' => $langRegExp, 'rules' => array( 'textRoot' => array( "/" => 'textRoot/index', ), 'textSection' => array( "/" => 'textSection/index', ), 'textPage' => array( "/" => 'textPage/index', ), 'aboutRoot' => array( "/" => 'about/index', ), 'aboutSection' => array( "/" => 'aboutSection/index', ), 'aboutPage' => array( "/" => 'aboutPage/index', ), 'partnersSection' => array( "/" => 'partnersSection/partners', "/" => 'partnersSection/partner', ), 'jobsSection' => array( "/" => 'jobsSection/jobs', "/" => 'jobsSection/job', ), 'sportRoot' => array( "/" => 'sport/index', "/study" => 'sport/study', "/awards" => 'sport/awards', "/team" => 'sport/team', ), 'sportSection'=>array( "/" => 'sportSection/index', ), 'sportPage'=>array( "/" => 'sportPage/index', ), 'albumsSection'=>array( "/" => 'albumsSection/albums', "/" => 'albumsSection/album', ), 'calendarSection'=>array( "/" => 'calendarSection/calendar', ), 'warrantyRoot' => array( '/' => 'warranty/index', ), 'questionRoot' => array( '/' => 'question/index', '/' => 'question/index', ), 'reviewsRoot' => array( '/' => 'reviews/index', ), 'workRoot' => array( "/" => 'work/index', "/" => 'work/brand', "//" => 'work/model', "///" => 'work/view', ), 'tuningRoot' => array( "/" => 'tuning/index', "/services/" => 'tuning/service', "/" => 'tuning/brand', "//" => 'tuning/model', "///" => 'tuning/view', ), 'newsRoot' => array( "/" => 'news/index', // "/feed" => 'news/feed', "/categories/" => 'news/category', "/show/" => 'news/show', "/view/" => 'news/view', "/publications/" => 'news/publications', "/publication/" => 'news/publication', ), 'saleRoot' => array( "/" => 'sale/index', "/" => 'sale/view', ), ) ), //sale section // "/sale" => 'sale/index', // "/sale/" => 'sale/view', //default routing rules "//" => '', "//" => '/', '/' => '', '/' => '/', ), ), 'db' => require('db.php'), 'errorHandler' => array( // use 'site/error' action to display errors 'errorAction' => 'site/error', ), 'log' => array( 'class' => 'CLogRouter', 'routes' => array( array( 'class' => 'CFileLogRoute', 'levels' => 'error, warning', ), array( 'class'=>'CFileLogRoute', 'levels'=>'info', 'logFile'=>'waterMark.log', 'categories'=>'waterMark.*', ), // uncomment the following to show log messages on web pages /* array( 'class'=>'CWebLogRoute', ), */ ), ), ), // application-level parameters that can be accessed // using Yii::app()->params['paramName'] 'params' => array( 'languages' => array( // 'uk', 'ru', 'en', ), 'languageNames' => array( // 'uk' => 'Українська', 'ru' => 'Русский', 'en' => 'English', ), // this is used in contact page 'adminEmail' => 'webmaster@example.com', ), );