Yii OpenCMS
Demo: http://www.mediatic.com.co/proyectos/yiiopencms/
FEATURES
- Backend and Frontend
- Bootstrap 2.3
- CMS Multilanguage Support I18n
- System & App Multilanguage Support I18n
- Cruge RBAC Reference: http://www.yiiframework.com/extension/cruge
- Based on NordCMS 2.0 Reference: https://bitbucket.org/NordLabs/nordcms
DIRECTORY STRUCTURE
Reference: https://github.com/bryglen/yii-advanced-template
/protected
config
backend.php contains backend configurations
common.php contains shared configurations
dbconnect.php contains DB configuration
frontend.php contains frontend configurations
params.php contains global app parameters
routes-back.php contains routes for backend app
routes-front.php contains routes for frontend app
controllers
backend/ contains backend controller
frontend/ contains frontend controller
models
_base contains base models (generated by gii)
_common contains common classes used in backend, frontend
backend contains backend-specific classes
frontend contains frontend-specific classes
/environment.php contains production or develop config
/index.php contains Yii Route
GETTING STARTED
Change Permission for:
1. /assets - change permission to writable by webserver
2. /protected/runtime - change permission to writable by webserver
3. /uploads - change permission to writable by webserver
4. /files - change permission to writable by webserver
Open /index.php and modify it according to the following example:
<?php
$environment = require_once(dirname(__FILE__).'/environment.php');
$config = dirname(__FILE__) . "/protected/config/frontend.php";
// change the following paths
$yii=dirname(__FILE__).'/../framework/yii.php';
require_once($yii);
Yii::createWebApplication($config)->runEnd('frontend');
Open /backend.php and modify it according to the following example:
<?php
$environment = require_once(dirname(__FILE__).'/environment.php');
$config = dirname(__FILE__) . "/protected/config/backend.php";
// change the following paths
$yii=dirname(__FILE__).'/../framework/yii.php';
require_once($yii);
Yii::createWebApplication($config)->runEnd('backend');
Import database:
// Create db yiiopencms and import de following
protected/data/yiiopencms.sql
Open protected/config/dbconnect.php and modify it according to the following example:
<?php
return array(
'connectionString' => 'mysql:host=localhost;dbname=yiiopencms',
'emulatePrepare' => true,
'username' => 'admin',
'password' => 'admin',
'charset' => 'utf8',
'schemaCachingDuration' => 60*60,
);
Enjoy
Open your browser:
// Go to:
http://localhost/yiiopencms
http://localhost/yiiopencms/backend
user:admin
paswd:admin
Author: juankaka@gmail.com
Version: 0.2.1