README.md 1.93 KB
Newer Older
1 2
Yii 2 Basic Application Template
================================
3

Qiang Xue committed
4 5
Yii 2 Basic Application Template is a skeleton Yii 2 application best for
rapidly developing small Websites containing mainly informational pages.
6

Qiang Xue committed
7 8 9
The template contains the basic features including user login/logout and a contact page.
It includes all commonly used configurations that would allow you to focus on adding new
features to your application.
10 11 12 13 14 15 16 17 18 19 20 21


DIRECTORY STRUCTURE
-------------------

      commands/           contains console commands (controllers)
      config/             contains application configurations
      controllers/        contains Web controller classes
      models/             contains model classes
      runtime/            contains files generated during runtime
      vendor/             contains dependent 3rd-party packages
      views/              contains view files for the Web application
22
      web/                contains the entry script and Web resources
23 24 25 26 27 28



REQUIREMENTS
------------

Qiang Xue committed
29
The minimum requirement by this application template that your Web server supports PHP 5.4.0.
30 31 32 33 34


INSTALLATION
------------

Qiang Xue committed
35
### Install from an Archive File
36

Qiang Xue committed
37 38
Extract the archive file downloaded from [yiiframework.com](http://www.yiiframework.com/download/) to
a directory named `basic` that is directly under the Web root.
39

Qiang Xue committed
40
You can then access the application through the following URL:
41 42

~~~
Qiang Xue committed
43
http://localhost/basic/web/
44 45 46
~~~


Qiang Xue committed
47
### Install via Composer
48

Qiang Xue committed
49 50
If you do not have [Composer](http://getcomposer.org/), you may install it by following the instructions
at [getcomposer.org](http://getcomposer.org/doc/00-intro.md#installation-nix).
Tobias Munk committed
51

Qiang Xue committed
52
You can then install this application template using the following command:
Tobias Munk committed
53

Qiang Xue committed
54
~~~
55
php composer.phar create-project --stability=dev yiisoft/yii2-app-basic basic
Qiang Xue committed
56
~~~
Tobias Munk committed
57

Qiang Xue committed
58 59
Now you should be able to access the application through the following URL, assuming `basic` is the directory
directly under the Web root.
Tobias Munk committed
60 61

~~~
Qiang Xue committed
62
http://localhost/basic/web/
Tobias Munk committed
63 64
~~~