Php plug-in installation and Xdebug configuration in Eclipse

Source: Internet
Author: User
Tags vc9

Since the android development team is fascinated by android automated testing, all of them have been using Eclipse as development tools. In the past, Zend Studio 9.0.1 was used as a PHP development tool and Zend Studio 9.0.1 was abandoned. With the Eclipse PHP development plug-in, we plan to use Eclipse for development in the future. This is convenient. Installing the PHP plug-in on Eclipse is very simple, you can go to the http://sourceforge.net/project/showfiles.php? Group_id = 57621 download the plug-in. Decompress the downloaded plug-in. Put the files in the decompressed features folder in the features folder of eclipse. Put the files in the decompressed plugins in the eclipse plugins folder.

Configure the PHP debugging function of Eclipse

The detailed process is as follows.

Download and install the software

Jdk is absolutely necessary. It is the most basic requirement for running Eclipse. Download it here.

Eclipse integrates the PHP development plug-in version. Download it here, select the version of your own operating system, and then download it to your local computer.

XDebug is downloaded here. Select a file to download based on your PHP version.

Episode: How to Select XDebug for PHP 5.2.17.17

1. Open Logging.

2. Go to the http://www.xdebug.org/download.php page, and you will see a lot of similarities and differences. Here is a question: what does VC9, VC6, and TS mean? If you have any questions, please visit: differences between ts and ETS-vc6 and vc9 compiling versions in PHP
3. We learned that XDebug of PHP 5.2.17.17 should download PHP 5.2 VC6 TS of Xdebug 2.1.2. For 32-bit or 64-bit systems, it depends on your machine.

Because

Apache + PHP is recommended for any server.

Install software

After installing JDK, configure the system variables as follows:

The second is to install Eclipse. Eclipse does not need to be set. As long as JDK is set up, Eclipse can be directly run at any location.

Xdebug Installation

Put the file in the php/ext folder.

XDebug Configuration

Open php. ini

Add the following configuration code to the last line. The configuration instructions are commented out.

Copy codeThe Code is as follows:
[Xdebug]

; Load Xdebug
Extension = php_xdebug-2.1.2-5.2-vc6.dll
; Enable Automatic Tracking
Xdebug. auto_trace = On
; Enable exception tracking
Xdebug. show_exception_trace = On
; Enable Automatic Start of remote debugging
Xdebug. remote_autostart = On
; Enable remote debugging
Xdebug. remote_enable = On
; Collect Variables
Xdebug. collect_vars = On
; Collect return values
Xdebug. collect_return = On
; Collect Parameters
Xdebug. collect_params = On

Save and restart the server.

Use phpinfo () to view the php configuration. If the installation is successful, you can see the following information:

The following describes the Eclipse configuration.

1. Failed to start, stop, and restart the apache service through Eclipse.

Cause:

A. The configuration is incorrect. The correct configuration is shown in:

2. Because I use the PHP Integration Environment encapsulated by phpstudy2011B, the apache service name is apache2, but apache2.2 is started by Eclipse by default, therefore, after I change the name of the registered apache service to apache2.2, it will be normal.

Enable CI in Eclipse and multiple warnings are displayed.

Similar information:

Description Resource Path Location Type The local variable $ _ ci_path may not have been initialized Loader. php/CI/system/core line 752 PHP Problem

As shown in:

It means that the local variable is not initialized, that is, the initial value is not assigned. This is common in PHP. So it seems a little uncomfortable to give so many warnings. Remove it.

Solution:

Change the selected content in red from the original warning to Ignore.

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.