Skip to content

bryglen/yii-advanced-template

Repository files navigation

Bryan Tan Yii Advanced Application Template

DIRECTORY STRUCTURE

/protected
    config
        api/            contains api configurations
        backend/        contains backend configurations
        common/         contains shared configurations
        console/        contains console configurations
        frontend/       contains frontend configurations
        test/           contains test driven development configurations
    controllers
        api/            contains api controller
        backend/        contains backend controller
        frontend/       contains frontend controller
    models
        _base           contains base models (generated by gii)
        _common         contains common classes used in backend, frontend and api
        api             contains api-specific classes
        backend         contains backend-specific classes
        frontend        contains frontend-specific classes

/environment.php         contains environment-based

REQUIREMENTS

The minimum requirement by Yii is that your Web server supports PHP 5.3.0.

In order for captcha to work you need either GD2 extension or ImageMagick PHP extension.

INSTALLATION

Install via Composer

If you do not have Composer, you may download it from http://getcomposer.org/ or run the following command on Linux/Unix/MacOS:

curl -s http://getcomposer.org/installer | php

You can then install the application using the following command:

php composer.phar create-project --stability=dev bryglen/yii-advanced-template yii-advanced

Install from repository

Download source code from repository

GETTING STARTED

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. /environment.php - add your absolute path to $local_path
5. /protected/config/dbconnect.local.php - create a file and copy the format in dbconnect.sample.php (local development) and change the configuration

you should be able to access:

  • the frontend using the URL http://localhost/bryantan/
  • the backend using the URL http://localhost/bryantan/backend/
  • the api using the URL http://localhost/bryantan/api/

make sure you enable the modrewrite rule

Reference: http://www.yiiframework.com/doc/guide/1.1/en/topics.url#hiding-x-23x

Inspired By: http://www.yiiframework.com/wiki/63/organize-directories-for-applications-with-front-end-and-back-end-using-webapplicationend-behavior

Since: Oct 25, 2013

Author: [email protected]

Version: 1.0.0

About

bryan tan customized advanced template

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages