- 1 Introduction
- 1.1 About zentaoPHP
- 1.2 Features
- 1.3 License
- 2 Installation
- 2.1 System Requirement
- 2.2 Install zentaoPHP
- 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
- 4.1 Basic Concepts
- 4.2 Request Types
- 4.3 Create Links
- 4.4 Class: HTML, JS, and CSS
- 5 Advanced
- 5.1 Directory Structure
- 5.2 DAO
- 5.3 Pager Solutions
- 5.4 Data Validation
Install zentaoPHP
- 2018-07-11 10:19:22
- Renee
- 6793
- Last edited by tengfei on 2019-09-16 14:08:01
1. Runtime environment for Apache, MySQL and PHP
First, you have to make sure that you have the runtime for Apache, MySQL and PHP, and they meet the system requirements for zentaoPHP.
2. Download the latest zentaoPHP
Go to ZenTaoPHP 3.1 and download the latest version of zentaoPHP. It is .zip file.
3. Install zentaoPHP
Unzip the downloaded file to a directory, e.g. /var/www/zentaophp, and you will find directories named framework, module, and lib. Put the application you want to develop under the directory of a module.
4. Create a database for the demo
Before you use zentaoPHP, you have to create a database for your demo. Use PHPMyAdmin or MySQL command lines to create it. Then go to the directory of ds and find blog.sql, and then generate a form of blog.
5. Generate config files
Go to the directory of config and copy my.example.php, and rename it as my.php. Then change the parameters of the database, namely the parameters of host, port, name, user, and password.
<?php $config->installed = true; $config->debug = true; $config->requestType = 'PATH_INFO'; // PATH_INFO or GET. $config->requestFix = '-'; $config->webRoot = '/'; $config->db->host = 'localhost'; $config->db->port = '3306'; $config->db->name = 'demo'; $config->db->user = 'root'; $config->db->password = '';
6. Visit demo application
Visit http://localhost/zentaophp/ in your browser, and you will the welcome page of zentaoPHP.
SCREENSHOT
Note: The path might vary according to the way you deply your zentaoPHP. localhost can be the actual IP address or domain you set.