PHP is very interesting and boring, so it's time to choose PHP. It took some time to install PHP. This is not the current PHP development tool.
Eclipse is a good ide Editor, not because it is good, but because it was used before, so it was chosen.
Configuration:
Eclipse3.2 and phpeclipse 1.1.8 (net.sourceforge.phpeclipse_1.1.8.bin.dist.zip)
Servers and PHP
In Apache 2.2
PHP 5
MySQL servers 5.2
Procedure
Decompress phpeclipse(net.sourceforge.phpeclipse_1.1.8.bin.dist.zip) and put it in the eclipse directory. The General Plug-in installation method is the same.
Restart eclipse or add the-clean parameter. Set phpeclipse. There is a phpeclipse web development item in the preferences of Eclipse,
The content to be set includes the following two parts:
PHP external tools
Set the PHP-related and APACHE-mysql-related Paths Based on the path information. Here, we mainly set PHP.
Run php Command: D: \ Server \ PHP \ php.exe
Parser command: D: \ Server \ PHP-l-f {0}
Project defaults is very important here. In many cases, the Development Environment fails because it is not configured properly.
The configuration here is related to the Apache configuration of the local machine. The specific steps are as follows:
Add Apache Virtual Host Name
The purpose is to facilitate development. Of course, this is also because there are several sets of web services running on the local machine, so we need to differentiate them. If it is only development, it is much simpler.
Modify the hosts file and specify the corresponding domain name and IP address. The local host is c: \ winnt \ system32 \ drivers \ etc \ hosts:
127.0.0.1 localhost
127.0.0.1 PHP. Dev
The PHP. Dev name is added, so that when you use this name in the browser, it will directly correspond to the previous IP address.
Add an Apache Virtual Host to the end of the configuration file httpd. conf:
Namevirtualhost FIG: 8080
<Virtualhost127.0.0.1: 8080>
Servername PHP. Dev
DocumentRoot "E:/phpworkspace /"
Errorlog logs/PHP. dev_errorlog.log
Customlog logs/PHP. dev_accesslog.log common
<Directory "E:/phpworkspace">
Options indexes followsymlinks Multiviews
AllowOverride none
Order allow, deny
Allow from all
</Directory>
ScriptAlias/PHP/"D:/Server/PHP /"
Addtype application/X-httpd-PHP. php
Action application/X-httpd-PHP "/PHP/php-cgi.exe"
</Virtualhost>
Set phpeclipse-> Project defaults
Localhost: http://php.dev: 82
DocumentRoot: e:/Eclipse/workspace/
Note: The reason why DocumentRoot chooses this directory is that this is the Development Directory of eclipse, and the directory of the PHP project can be used for testing.
Note: The following virtual hosts are known on the Internet. If Apache cannot be started as described above, you can configure the following:
<Virtualhost127.0.0.1: 8080>
Servername PHP. Dev
DocumentRoot "E:/phpworkspace /"
Errorlog logs/PHP. dev_errorlog.log
Customlog logs/PHP. dev_accesslog.log common
<Directory "E:/phpworkspace">
Options indexes followsymlinks Multiviews
AllowOverride none
Order allow, deny
Allow from all
</Directory>
</Virtualhost>