The PHP plugin for Eclipse provides support for XAMPP, so with these three pieces installed, you can use Eclipse's built-in browser to immediately view the code you've written or modified. Step 1 - Eclipse Download Eclipse Classic from here. Extract the files into the directory of your choosing (for example, C:Program Files). Utc to ist. XAMPP is a distribution of Apache HTTP Server that also includes PHP 5.0.x, MySQL and other useful software. As of October 2006, version 1.5.4 seems to contain the right versions of the parts we need. The first step is to actually obtain XAMPP from the download web site. To setup Xdebug as your default debugger in PDT, simply configure the Default Settings in the Debug eclipse preference page of PHP Configuration. The most important setting for Xdebug to work with PDT is xdebug.remoteenable = 1. Typically you set this value in your php.ini. To verify that Xdebug. Download Eclipse PDT (PHP Development Tools) from: Download 32 bit or 64 bit version. Extract the eclipse-php-neon-R-win32-x8664.zip file. Double click on Downloadseclipseeclipse.exe to start Eclipse. Accept default workspace and click OK. Allow eclipse.exe to the Windows Firewall when a window pops up. XAMPP and Zend Eclipse PDT are free software.Downnload XAMPPIn this video we will setup XAMPP and Zend Eclipse PDT for PHP project.Home » Language IDEs » PHP Development Tools (PDT) » XAMPP to run PHP Scripts - which version?
|Show:Today's Messages::Show Polls::Message Navigator|
|Previous Topic:||Set up RUN Configuration - How?|
|Next Topic:||Emulate MySql data base in Eclipse PHP Project|
1. Download and install Eclipse IDE(Indigo or later versions of Eclipse IDE), XAMPP.
2. Install PDT on Eclipse. Refer http://wiki.eclipse.org/PDT/Installation for instructions.
3. Install BitNami WordPress or Drupal or Joomla, or all of them on XAMP. Those can be installed easily on the XAMPP admin page, Applicaions.
4. Download the xdebug dll file. This wizard will tell you the version of xdebug file you need http://xdebug.org/wizard.php
5. Configure the php.ini file to use the xdebug dll downloaded from step 4.
- a. Assume the XAMPP home is C:xampp, put the xdebug dll file to C:xamppphpextphp_xdebug-2.2.3-5.4-vc9.dll
b. Open C:xamppphpphp.ini, and put the following at the end of the file. If those are already there, modify them to look like the below.
c. Restart Apache server on XAMPP’s admin panel.
d. Go to XAMPP admin page, and then go to phpinfo(). Search for xdebug on the phpinfo page to make sure xdebug is installed. If you can see the above configuration on the phpinfo page, that means the xdebug was installed successfully.
6. Configure Eclipse PDT to use XDebug.
- a. Create a new PHP project from a existing directory, for example, the Drupal installation directory, C:xamppappsdrupalhtdocs
b. Window->Preference->PHP->Debug, make the settings like this
- PHP Debugger: XDebug
Server Default PHP Web Server
PHP Executable: PHP 5.4.7
c. Window->Preference->PHP->Debug->Installed Debuggers->Select XDebug and click Configure, make the below settings
Debug Port 9002
Accept remote session (JIT) localhost
d. Window->Preference->PHP->PHP Executables, this should have configured already if when setting php executables from step b.
e. Window->Preference->PHP->PHP Interpreter->Select PHP 5.4
f. Window->Preference->PHP->PHP Servers->Click New, and put the below settings
- Name can be anything, Default PHP Web Server
Base URL: http://localhost
Local Web Root: C:xampphtdocs
Eclipse Xampp Server
7. Install XDebug Helper on Chrome. Once this is installed, a bug will show up in the address bar. The color will be green when enabled, grey when disabled.
8. Open the Drupal index.php in Eclipse, put a breakpoint next to a line of code, right click the file on the explorer, Debug As PHP Web Application.
9. Make sure the bug is green in the address bar. Load the Drupal home page on Chrome, with BitNami Drupal installed, the link should be http://localhost/drupal/, and the page will not be loaded fully, it will stop at the breakpoint you put in Eclipse.Now we can start debugging in the Eclipse Debug mode.
10. If there are any issues, make sure the below are sound.
- a. The ip address for xdebug.remote_host in the php.ini file is 127.0.0.1
b. The Accept remote session (JIT) in Eclipse setting is localhost
c. The xdebug.remote_port is matched up the Debug port in Eclipse, 9002
d. The bug icon of the XDebug Helper in the Chrome address bar is enabled with green color
e. Make sure the localhost is pointing to 127.0.0.1
f. Try not to use any port numbers other than 80 for the web application, the default port number for Apache loacalhost
g. Last advice, try to get the XDebug working with the simplest web application first, it could as simple as a php hello world page first.