I have installed Xampp on Windows (Well actually both xampp and wamp but both have the same problem), and enabled xdebug. I have installed the latest eclipse for php with pdt included. The breakpoints are working correctly however if I press f6 or f5 the current line does not get updated, the variables change as if I had stepped to the following line but the highlighted line remains the same. Any ideas?
I attach some screenshots to make it easier to understand:
Breakpoint works:
I press f6, lineno and $a changes in the 'Debug' and 'Variables' window:
I press f6 again:
I tried updating to the latest xdebug but the same thing happens.
This is problem in Eclipse SR1. You should switch back to R (SR0) release, next you can install PDT 3.3.1 from marketplace.
See also bug report on bugzilla
Edit:
Problem is fixed in nightly builds: http://download.eclipse.org/tools/pdt/updates/3.4-nightly/
Edit 2:
We released new stable (3.3.2) version with fix for this problem. You can find it on marketplace or in this update site: http://download.eclipse.org/tools/pdt/updates/3.3.2/
Goto Eclipse->Help->Install New Software
Work with: http://download.eclipse.org/tools/pdt/updates/3.3.2/ (this worked for me)
Alternative: You might want to use the latest stable update site: http://download.eclipse.org/tools/pdt/updates/latest/
[If not already existing]: click (Add) & give a name like "PDT" in order to add the upgrade site.
Type "PDT" and tick checkbox for "PHP Development Tools (PDT)"
Accept the license stuff and upgrade PDT.
Restart Eclipse
Related
I have installed eclipse php (Neon.2 Release (4.6.2)) with subversive (4.0.2) plugin.
When trying team synchronizing, I've got 2 issues :
The arrows icons (which gives a preview of what's to push and what to pull) disappear after 1 second.
This issue was solved by doing the following :
Install PDT addon v2.2.1 using "Install New Software" Select Heliosn
update site (http://download.eclipse.org/releases/helios) then use
filter "PDT" to display only PDT, and select "PHP Development Tools
(PDT) SDK Feature" then install
When double clicking on a .php to see what has changed, it's blank. Any other files work properly though.
1- I have neon 2 + PDT and the problem is gone disabling:
"window/preference/general/appearance/label decorations/PHP Project Explorer Decorator"
and close and reopen team synchronizing perspective
2- To resolve this problem "help/install new software" and use (nightly builds)
http://download.eclipse.org/tools/pdt/updates/latest-nightly/
and install all items,
bug reported here.
I hope that helps.
My PDT (Php plugin for eclipse) was broken.
I decided to install eclipse Lunar latest release, then installed latest subversion Lunar plugin and connectors, and it all worked out.
I am using Aptana 3 studio to work on my php (drupal) projects. All of the sudden, the debug function stopped working. It used to work flawlessly. Now when I select a debug configurtion and debug it, an empty page opens in firefox.
Is this connected with how Aptana communicates with the browser? With the server?...
EDIT:
So I decided to try a new thing altogether and installed a full new system based on LXLE 14.04 (based on the same ubuntu 14.04, which I used in a full unity version before).
Now, after some quirks, I have a running debug in Aptana on that system. I am pretty sure, though, that this is the configuration that worked for me in the first place.
I also remarked some weird window behavior on the system - sometimes the Aptana window would get so small it is hardly noticable (1px*1px?) and gets to the top left corner.
I found that setting xdebug.remote_autostart=1 in php.ini and restarting Apache allows me to debug somewhat. Although Firefox still opens a blank page, opening the page myself in the browser now allows me to get a break in Aptana.
I am using Eclipse for PHP Luna Service Release 1 (4.4.1), and try to install xdebug for debugging. I follow this blog for for setting xdebug on xampp 1.8.1. Follow is my php.ini settings.
[XDebug]
zend_extension = "C:\xampp\php\ext\php_xdebug.dll"
xdebug.remote_enable = 1
xdebug.remote_handler = "dbgp"
Basically it will stop on the break point i set, but then i press [F6], it will not go to next line.
But in debug dialog window, line number keep going, and variables also change too.
Does anyone knows what wrong on this? thanks.
I think I found a bug report on this issue:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=445903
It's marked as solved, so maybe on the next release this issue should be gone.
EDIT: updating PDT to version 3.3.2 http://download.eclipse.org/tools/pdt/updates/3.3.2/ solves this issue (at least in my install)
Yes, this seems to be a bug, I hit it after updating.
It does step to the next line though, it just doesn't update the highlight and current position.
Over the last few years I've experienced quite a few of such annoying bugs in Eclipse IDE for PHP Developers (PDT) with official updates. One might get the impression that the developers don't pay much attention to regression testing.
Solution:
If you've updated Eclipse recently, open "Help" -> "Installation Details". Click on the tab "Installation History" and find an entry that doesn't contain version 4.4.1 (it's 4.4.0.20140612-0500 here).
The Eclipse project page is a bit messy in my opinion (or I'm just blind), but you can fortunately crawl a mirror site to find older releases:
http://ftp.yz.yamagata-u.ac.jp/pub/eclipse/technology/epp/downloads/release/luna/R/
I also had the same problem, where the stepping through the code would not go to the next line. I realized that the problem was that the remote php script which I was debugging, had a line of code which was not present in the local php script in Eclipse. Updating the local php script to match the remote php script fixed the problem.
I'm currently running Komodo 7 and have XDebug set up on PHP 5.3.1, which is installed as part of XAMPP 1.7.3. All of this is running on Mac OS X 10.7.
Until I upgraded XAMPP (from version 1.0.1) step-through debugging of PHP in Komodo was working fine. I'd load a page in Firefox and the Komodo icon in the dock would start bouncing up and down, and I'd be able to step through my code, add breakpoints, etc.
It now seems that debugging isn't working properly. I'm confident that XDebug is set up properly, as it shows up when I run phpinfo(). However, when I load a page in Firefox, step-through debugging doesn't start in Komodo. Komodo does respond to an extent, in that information is displayed in the "Debug Output" pane in the bottom-right of the Komodo window, but there's no way I can see to start step-through debugging.
I've got a project I need to finish, so I'd really appreciate any help anyone is able to offer.
As per Hamish's comment above, this is indeed a duplicate (of sorts) of Can't get PHP debugging to work with Komodo (but I'm almost there!)
See that question for something approaching an answer.
I would like to know how i can get XDebug work with Aptana Studio 3 (I already have Aptana Studio 3 on this machine with XAMPP).
Do you know a recent article telling me how to do this and explains XDebug? I have no experience nor any knowledge about XDebug, i looked for articles but all seem outdated to me.
I realize that this is a old thread but I also had a difficult time finding out how to debug php with Aptana Studio and FireFox so here is a quick how-to to get it working...
The easiest way I found is to install wamp server V2.2, this is a very useful program as it installs Apache Server, PHP and MySQL and other tools, everything can be easily configured via the taskbar.
1.) Install Aptana Studio V3.3.X or higher Download here
2.) Install WampServer V2.2 or higher Download here (XAMMP users read bottom).
WampServer:
1.) Make sure XDebug is accepting remote debug, click on the WampServer icon in the taskbar and go to PHP->PHP Setting and make sure that "(XDebug): Remote debug" is checked if not select it click on the WampServer icon and "Restart all services".
2.) Verify that XDebug is running:
a.) If you had WampServer insert index.php enter "localhost" in the URL and under "Tools" click "phpinfo()" and check to make sure XDebug is running, you should see the following in FireFox:
b.) If you didn't overwrite the index.php create a file (/www_dir/phpinfo.php) with the following:
<?php
phpinfo();
?>
b.1) In FireFox enter "localhost/phpinfo.php" and look for XDebug as shown in the previous image.
Aptana Studio:
1.) Click Window->Preferences
2.) In the Preferences dialog go to Aptana Studio->Editors->PHP->PHP Interpreters
3.) Click "Add..."
4.) Enter the information like
5.) Click "OK"
6.) Click on the debug icon and select "Debug Configurations"
7.) Double click on "PHP Web Page"
8.) Click the plus next to "PHP Server"
a.) Enter a name
b.) Base URL will be "localhost"
c.) Document Root will be the path to your index.php
Finally in Aptana Studio click the Debug Icon Arrow and select the configuration you named above. If Firefox prompts you install the Aptana Studio plugin...
Hope this helps out...
-------------
XAMPP USERS
-------------
Follow the steps provided but your directory link in the
In the Preferences dialog go to Aptana Studio->Editors->PHP->PHP Interpreters
should link to C:\xampp\php\php.exe and C:\xampp\php\php.ini respectively
***** UPDATE *****
If you are using Firefox V20+ there are some compatibility problems with Firebug V1.8+ that basicly breaks Firefox's context menus, I could not find a fix for it so I ended up having to go another route and figured I should make a post, Aptana Studio is based on Eclipse so the best way IMHO to get PHP Debugging is to install Eclipse with PDT and remove Aptana Studio... The above instructions will work to get everything working with XDebug
Here is a nice link on how to get everything up and running eclipse-pdt
At the moment, there is no PHP debugger support in Aptana Studio 3. However, there will be soon. See: http://jira.appcelerator.org/browse/APSTUD-769 and add yourself as a watcher to get informed when it's done.
For now, you can install PDT from eclipse.org if you really need to debug.
They also provide up-to-date docs on how to use it. There is a small learning curve, but it will work pretty much the same in Aptana (once it's released), so you have nothing to lose :)
Here is a mini how-to configure and start using XDebug with Aptana Studio 3.3, assuming you have installed xdebug on your system. (In Ubuntu/Linux it's just a sudo apt-get install php5-xdebug).
Configure the debugger
In preferences->Aptana Studio->PHP->PHP Interpreter click on Add..., and specify a name, the php executable(/usr/bin/php in most Linux distributions), the php.ini(/etc/php5/conf.d/20-xdebug.ini on my system), and leave XDebug in the select field of PHP debugger.
Using the debugger
Make a php file and put some code in it:
<?php
$defined_var = 'some value';
echo $defined_var;
echo $undefined_var;
exit();
?>
Save it and press Run->Debug As->PHP Script and you will be prompted to switch Workspace.
Specify a Line Breakpoint by double clicking next to a line number, for example at the line of exit() function.
Press Resume(F8) and you can see that the Debug Current Instruction Pointer moved there.
At the variables tab, you should now see which variables have some value or they are uninitialized. The output can be found at the console tab.
Pressing resume again will terminate the debug.
Of course, this is only the tip of the iceberg regarding debug, but it's a start.
There are many other options to explore and ways to debug your scripts.
I have use Aptana Studio 3.2.2 to develop my Drupal site and use XDebug to debug the project. The Aptana Studio supports xdebug. You need to follow some steps to enable xdebug in Aptana Studio.
Configure xdebug in your php engine properly.
Edit the preference by going Preference -> Aptana Studio -> Editor -> PHP Interpreter.
Add a PHP interpreter and save it.
Now create a new Web Server if no web server is currently working.
Now Apply the changes.
Next, Edit the Debug Configuration using Run -> Debug Configurations -> PHP Web Page.
Add a new web page by selecting a initial script file for the php project.
In the last step, start debugging.
You can find a details step by step procedure in the following link:
http://devcircle.blogspot.com/2013/02/enable-xdebug-in-aptana-studio-3x.html
Hopefully it helps to solve the problem.
For me it worked only after
1. Performing stuffs from here (basically - setting-up the XDebug for remote debugging)
https://jira.appcelerator.org/secure/attachment/26404/ScriptPHPDebugging.pdf
2. installation of "XDebug helper" for chrome, and something similar for FF.
After that I have my remote sessions working just-like-they-did-in-Eclipse.