Configure Eclipse PDT with X-Debug and XAMPP

In my Past days, i was trying to figure out the setup of Eclipse PDT with X-Debug and XAMPP for debugging a PHP Application..From my friends help,at last i configured it properly and make it up and running.

Here are the steps for the setting up the configuration.

Step 1:

Download the Eclipse PDT.

Step 2:

Download the XAMPP 1.7.2 .

Step 3:

Install the Eclipse and XAMPP and Check that Eclipse and XAMPP Server is up and running.

Step 4:

To make sure the XAMPP Server is running.Open your web browser and type in the URL(“http://localhost” without quotes). And you should see the XAMPP Start up Page.

Step 5:

Now stop the XAMPP Server.Navigate to the XAMPP installation directory. And you will find the ‘htdocs’.Create a PHP File inside that directory.

Thats looks like this

<? php

echo phpinfo();


Save the File with any name you wish to have(For example:sample.php).And then start the XAMPP Server.

Then open your browser and start typing in the URL(“http://localhost/sample.php&#8221;)

You will see all your information about the XAMPP Server.

There you will have particular information that where is your ‘php.ini’ is located.

Step 6:

Stop your XAMPP Server, navigate to the ‘php.ini’  file directory then open the file in notepad .

Go to last line of the ‘php.ini’ file and add the lines that shown just below

[Zend Debug]

Now save the file and close it.Now Start the XAMPP Server again.

Step 7:

Now open your Eclipse.

Create a ‘New PHP Project’ and Create a New File in that with any name you wish to have(For Example ‘test.php’)

In that ‘test.php’ have a small php code to test it.

For example


echo “any text you wish”;


Save the file.

Step 8:

Now ,we are going to configure the debugging part.

Select your project directory in eclipse and then click on ‘Window–>Preferences’

In that expand the ‘General’ tab you will see ‘Web Browser’ click on that and then select your web browser you want your output to be displayed.

Then Apply the Setting.

Navigate to the ‘PHP’ Tab and expand it on the left hand side of the ‘Preference’ window.

You will see the ‘Debug’ tab’ and click on that.

In that screen,

Leave the below thing as Default

PHP Debugger is Zend Debugger and click on Configure in that then you will have two servers that will be listed over there.Click on XDebug and select ‘configure’ you will have ‘Access remote session(JIT)’ should be ‘localhost’ . select that and click ‘OK’.

Sever is Default PHP Web Server

then  below that click on ‘PHP Executable s’.Click on ‘Search’ and locate where the XAMPP Server is installed and then click ‘OK’.

After a few minute it will show you one ‘PHP Executable’ listed over there.

Select that click on ‘Edit’ .

There you will have PHP ini File (Optional)

Click on ‘Browse’ in that navigate to ‘XAMPP Server installation Directory and there you will find ‘PHP’ Directory in that select ‘php.ini’ and then click ‘OK’ and then below that you will ‘PHP Debugger’ as ‘XDebug’.

Then apply the Setting and then click ‘OK’.

And then click ‘OK’ to apply the over all setting that you have made to it.

Now fix the breakpoint in a file and ‘Debug’ the File and see the output.

Its all configured properly.

Thanks for all my friends to share their ideas to fix up this.


1 thought on “Configure Eclipse PDT with X-Debug and XAMPP”

  1. if i dont want to work with php, what can i do to connect my eclipse project to xampp ,as a problem i face:”i need a connector from my eclipse juno, to xampp without using php” plzzz need help

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s