Zend framework Environment configuration (win7)

Source: Internet
Author: User
Tags php source code

Introduction: This is a detailed page of Zend framework Environment configuration (win7). It introduces PHP, related knowledge, skills, experience, and some PHP source code.

Class = 'pingjiaf' frameborder = '0' src = 'HTTP: // biancheng.dnbc?info/pingjia.php? Id = 350657 'rolling = 'no'>
Confirm the PHP and Apache environment Configuration:

1. Check whether your PHP version is 5.2.0 or above. If not, update it to 5.2.0. Otherwise, the. Zend framework may not be used.

PHP source code Latest Version: http://www.php.net/downloads.php.

2. After your PHP environment is configured, open the php. ini file and check whether the PDO extension is Enabled:

; Extension = php_mysql.dll
; Extension = php_pdo.dll
; Extension = php_pdo_mysql.dll
Modify
Extension = php_mysql.dll
Extension = php_pdo.dll
Extension = php_pdo_mysql.dll remove the semicolon
Also:
; Windows: "\ path1; \ path2"
Include_path = ".; C: \ PHP \ shortdes; E: \ wwwroot \ zendf \ library" (supported by libary of Zend Framework)

3. Open the httpd. conf file in the Apache folder. Configure mod_rewrite.so support.

# Loadmodule rewrite_module modules/mod_rewrite.so
Modify: loadmodule rewrite_module modules/mod_rewrite.so (remove #) to support Zend framework

4. Find the httpd. conf file. If AllowOverride is set to none, change none to all. In this way, you can write files such as. htaccess ..

Replace all: AllowOverride none with AllowOverride all. htaccess files supported

5. Restart your Apache server so that Zend framewrok can be used in our PHP environment.

 

Install Zend Tool

Download the Zend framework ZIP file, decompress it, and configure the path of the environment variable:

Add the following at the end of the PATH variable:

; D: \ Program Files \ Zend \ zendframework \ bin

This path is the path of the bin directory in the decompressed directory. Pay attention to the preceding path. Do not discard it.

Test whether the installation is successful:

Enter:

ZF show version

This statement shows the version. If it succeeds, the version will be output; otherwise, an error will be reported. Here I show:

Zend Framework Version: 1.11.10

 

Create a project

You can use zendtool to create a project. The command line is as follows:

Enter the site root directory (usually the htdocs directory) through the command line, and type the command:

ZF Create Project zf_proj

Press enter to create a zf_proj Directory, which automatically creates necessary files and folders. The directory structure is as follows:

If you have not installed the unit test tool phpuint, a prompt will be displayed, but it does not matter. Ignore it.

Of course, you can also copy the downloaded directory to the self-built directory. The command did not do any configuration work.

Generally, images, JS files, and CSS files must be under the public directory, while zendframework files in the library folder must be put down, you can copy the contents in the library folder in the compressed package (in fact, there is only one Zend folder.

Now, let's test the following link:

Http: // localhost/zf_proj/public/

You can see the welcome page.

Love J2EE follow Java Michael Jackson video station JSON online tools

Http://biancheng.dnbcw.info/php/350657.html pageno: 3

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.