- 1 Introduction
- 2 Installation
- 3 Quick Start
- 3.1 Echo Hello World!
- 3.2 Use MVC to echo Hello World!
- 3.3 Example: Deploy the blog built in zentaoPHP
- 4 Basics
- 5 Advanced
Directory structure is important for a framework. Let's see the directory structure of zentaoPHP.
1. Root Directory
config: configuration files, including config.php and my.php
db: blog.sql required in demo application
framework: core files of the framework
js: js script files
lib: common class files
module: module directory; each module has a directory
theme: theme files, including CSS files and image files
.htaccess: URL rewrite rule files in Apache
favicon.ico: small logo files
- index.php: entry program
2. Module Directory
config.php configuration files for the module, and global configuration files
lang language files for the module. zh-cn is simplified Chinese, zh-tw is traditional Chinese and en is English.
control.php control files for the module
model.php service logic files for the module
- view view files for each page, e.g. index.html.php is the template file of the index method
common is to store common files for an application, such as lang, template, and model. For example, lang/en.php is for common language files, header.html.php is common header files for templates, footer.html.php is common footer files for templates, error.html.php is for common error message files.