#cmsRS
CmsRS is a cms base on:
- Yii2 advanced template
- AngularJS v1 (administration panel)
- CSS · Bootstrap (frontend and backend)
This is cutdown version of my cms. It is include:
- add pages and menu
- add content to the page
- upload and delete image
- set up langs
- log in to administration panel
Db scheme:
The full version available on the website:
http://www.cmsrs.pl/en/cms/cmsrs/about-cmsrs
-
Install:
git clone https://github.com/yiisoft/yii2-app-advanced.git cd yii2-app-advanced composer global require "fxp/composer-asset-plugin:^1.2.0" composer create-project --prefer-dist yiisoft/yii2-app-advanced cmsrs cd cmsrs git clone https://github.com/cmsrs/cmsrs.git rm -rf common frontend admin; mv cmsrs/* .; rm -rf cmsrs
-
Set db:
Change:
common/config/main-local.php
accordingly.Create table to database from
temp/cmsrs4.sql
in my case:mysql --default-character-set=utf8 -u cmsrs -ppass123456 cmsrs < ./temp/cmsrs4.sql
Insert admin user name demo/demo - to administration panel:
INSERT INTO `user` (`id`, `username`, `auth_key`, `password_hash`, `password_reset_token`, `email`, `status`, `created_at`, `updated_at`) VALUES (1, 'demo', 'u4qnlunMrSWqcyitTV06gH5C8ZlAaWar', '$2y$13$dN9ipH0Pc2zLBsDGfIkLOuZDvG0Lv5YACMWCAUIYeCHqNKfw3VbDa', NULL, '[email protected]', 10, 1428424049, 1428424049);
-
Set vhosts:
Frontend:
url:
cmsrs2.loc
/path/to/yii2-app-advanced/cmsrs/frontend/web/
Backend:
url:
cmsrs2admin.loc
(it is a important name)/path/to/yii2-app-advanced/cmsrs/admin/web/
<VirtualHost *:80> ServerName cmsrs2.loc DocumentRoot "/path/to/yii2-app-advanced/cmsrs/frontend/web/" <Directory "/path/to/yii2-app-advanced/cmsrs/frontend/web/"> # use mod_rewrite for pretty URL support RewriteEngine on # If a directory or a file exists, use the request directly RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d # Otherwise forward the request to index.php RewriteRule . index.php # use index.php as index file DirectoryIndex index.php # ...other settings... </Directory> </VirtualHost> <VirtualHost *:80> ServerName cmsrs2admin.loc DocumentRoot "/path/to/yii2-app-advanced/cmsrs/admin/web/" <Directory "/path/to/yii2-app-advanced/cmsrs/admin/web/"> # use mod_rewrite for pretty URL support RewriteEngine on # If a directory or a file exists, use the request directly RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d # Otherwise forward the request to index.php RewriteRule . index.php # use index.php as index file DirectoryIndex index.php # ...other settings... </Directory> </VirtualHost>
-
Edit hosts:
127.0.0.1 cmsrs2.loc 127.0.0.1 cmsrs2admin.loc
-
Run server side tests:
cd temp/scripts_cli ./go.sh
-
Config cms:
common/config/params.php
-
Backend:
http://cmsrs2admin.loc/admin/#
Create menu and pages
example:
-
Frontend:
http://cmsrs2.loc/
example: