Install zentaoPHP

2018-07-11 10:19:22
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.

$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.


Note: The path might vary according to the way you deply your zentaoPHP. localhost can be the actual IP address or domain you set.

Write a Comment
Comment will be posted after it is reviewed.