Eclipse PHP Environment Preparation

Source: Internet
Author: User
Tags php and mysql php development environment
Eclipse PHP Environment Setup

Reference to PHP and MYSQL Web development book and related network resources to build the Eclipse PHP development environment

Ready to work: Download Apache http://httpd.apache.org/?? Suffix to MSI

????????????? Download the PHP installation file? Http://windows.php.net/download/?installer

??????????? Download the Eclipse PHP version

?? Apache and PHP to install the default, in the process of installing Apache first, after installing PHP installer, this will be in Apache Conf directory httpd.conf files and PHP directory php.ini files for automatic configuration, We don't need to make any changes.

The content that is automatically modified should be:

In the php.ini file

? 1) Extension_dir = "./"??? Modified to Extension_dir = "C:/php-5.2.6/ext"
2); Extension=php_mysql.dll "and"; Extension=php_gd2.dll ", remove the preceding semicolon, that is, extension=php_mysql.dll change to Extension=php_ Mysql.dll
Change the Extension=php_gd2.dll to Extension=php_gd2.dll.
? 3). Save the php.ini and then re-start Apache

2. Modify the httpd.conf under apache/conf and add it at the end of the file:

LoadModule php5_module "C:/php-5.2.6/php5apache2_2.dll"
AddType application/x-httpd-php. php
AddType Application/x-httpd-php-source. Phps
Action application/x-httpd-php "/php/php-cgi.exe"
AddType application/x-httpd-php. html
AddType application/x-httpd-php. htm
Adddefaultcharset UTF8

Phpinidir "c:/php-5.2.6"

?

We need to be in the. Under the path setting for the environment variable, add:

C:\php-5.2.6; C:\php-5.2.6\ext

?

After the above configuration, create a PHP test file under the Apache/htdocs directory index.php as follows:

Php

? Phpinfo ();
?>

Remember to restart Apache.

Open IE in the address bar input: http://127.0.0.1/index.php, if you can work means that PHP and Apache can work.

?

Installation and commissioning Environment Xdebugger:

Download the Xdebugger file, is a DLL, put in the PHP ext directory, the php.ini file at the end of the add the following content

; onload Xdebug; loading Xdebug

zend_extension_ts= "D:/program Files/php/ext/php_xdebug-2.1.2-5.3-vc6-nts.dll"
; xdebug configuration;xdebug Configuration

[Xdebug]
; Turn on auto-tracking
Xdebug.auto_trace = On
; Turn on exception tracking
Xdebug.show_exception_trace = On
; Turn on remote debugging auto-start
Xdebug.remote_autostart = On
; Turn on remote debugging
Xdebug.remote_enable = On
; Collecting variables
Xdebug.collect_vars = On
; Collect return values
Xdebug.collect_return = On
; Collect parameters
Xdebug.collect_params = On

?

?

For example, I put all the eclipse projects under E:\EclipseWorkspace, then modify the apache/conf/httpd.conf and add it at the end of the file:

DocumentRoot "D:/phpworkspace"
# # #Alias/workspace? "D:/phpworkspace"

?? Options Indexes MultiViews
?? AllowOverride None
?? Order Allow,deny
?? Allow from all

?

The advantage of this is that all PHP projects share an Apache configuration (see how to set it below).

?

?

Installation of Pear:

?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
  • Related Article

    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.