Home > Backend Development > PHP Tutorial > centos configure php development environment (eclipse PDT+Zend Debugger)

centos configure php development environment (eclipse PDT+Zend Debugger)

WBOY
Release: 2016-08-08 09:21:32
Original
1121 people have browsed it

Reprinted from: http://blog.csdn.net/yang1982_0907/article/details/39026295

1. Environment description

Operating system: CentOS 6.4 x86_64

Java: jdk-1.7.0_51

Two , Install PHP

Run the following command in Shell:

yum install -y php httpd
Note: The PHP version installed through yum on CentOS 6.4 system is 5.3.3

3. Install Zend Debugger

Download Zend Debugger:

cd /root/Downloads
wget http://downloads.zend.com/studio_debugger/2011_04_10/ZendDebugger-20110410-linux-glibc23-x86_64.tar.gz
Note: The latest Zend Debugger only supports PHP 5.4 and 5.5 versions, and does not support PHP 5.3.3, so You need to download an older version of Zend Debugger.

Compress and install Zend Debugger:

tar -xvzf ZendDebugger-20110410-linux-glibc23-x86_64.tar.gz
cp -a /root/Downloads/ZendDebugger-20110410-linux-glibc23-x86_64/5_3_x_comp/ ZendDebugger. so /usr/lib64/php/modules/

Configure Zend Debugger:

gedit /etc/php.ini
Add the following lines below the [PHP] line in the above file:
zend_extension=/usr/lib64/php /modules/ZendDebugger.so
zend_debugger.allow_hosts=127.0.0.1
zend_debugger.expose_remotely=always

Since CentOS 6.4’s libssl and libcrypto have been upgraded to 1.0.0, and the above version of Zend Debugger needs to use version 0.9.8, so The following configurations are also required:

ln -s /usr/lib64/libssl.so.10 /usr/lib64/libssl.so.0.9.8
ln -s /usr/lib64/libcrypto.so /usr/lib64/ libcrypto.so.0.9.8

You need to set SELinux to permissive mode, otherwise PHP will not be able to load Zend Debugger:

gedit /etc/selinux/config
Change SELINUX=enforcing in the above file to SELINUX=permissive
Save Restart the system after configuring the file

4. Install Eclipse

Download Eclipse For PHP:

cd /root/Downloads
wget http://ftp.osuosl.org/pub/eclipse/technology/epp/downloads/release/luna/R/eclipse-php-luna-R-linux-gtk-x86_64.tar.gz

Unzip and install Eclipse For PHP:

tar -xvzf eclipse-php-luna-R-linux-gtk-x86_64.tar.gz
mv /root/Downloads/eclipse /usr/local/Eclipse4PHP

Create Launcher for Eclipse on the desktop, and then run Eclipse, set its Workspace to /var/www/html

5. Verification test

Start Apache:

service httpd start

Test whether PHP loads the Zend Debugger module:

php -m
If the above command If no error is reported and the following information is present, it means that the module is loaded successfully:
[Zend Modules]
Zend Debugger

Create a PHP test project in Eclipse and use the phpinfo() function to verify. If you see the following information on the page, then Indicates successful installation:

centos configure php development environment (eclipse PDT+Zend Debugger)

The above introduces centos configuration PHP development environment (eclipse PDT+Zend Debugger), including aspects of the content, I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template