Xdebug Not working with Notepad++ Not flashin (New)
By: Robert Davis (shaba1) - 2008-07-05 02:45
I set up notepad++ according to the instructions on the web site. I had already had xdebug set up in my php.ini file. I also followed the instruction at
Everything worked fine until part where I am suppose to enter
http://localhost/debugTest.php. I acutally use http://127.0.0.1/Robin/debugTest.php becasue that is where I saved the file. Well notepad++ does not "flash" as the tutorial said it should, the step over, Step Into,Run,Stop, Step Out,Run To menu choices and buttons are all greyed out. In the debugger section at the bottom of the notepad++ window it says disconnected. I have done a netstat -a -b and notepad++ shows as listening on port 9000. I even opened that port on my linksys router just to be sure that was not blocking things. even though I am running notepad on the actual machine that the php file is saved to.
After all this debugging still does not start. Does anyone have a reason why.
Maybe it would be more helpful for everyone if you provided components versions. Even apache one.
When you use Xdebug it's Apache who is responsible for connecting to npp. Older version of DBGp client also had some problem with never versions of xdebug and was not understanding correctly some signals from apache/php/xdebug combo. You should upgrade at least Xdebug and DBGp client.
I use npp 5.0.2 as server with Xdebug 2.1.0-dev on Apache 2.2/PHP 5.2.5 as client and the debugging is triggered using Firefox 3 and Xdebug 0.3 Extension and besides slightly broken breakpoint management in DBGp 0.0.8.16 everything seems fine.
In your DBGp settings dialog, "idekey" must match the "idekey" defined in the Firefox extension or cookie to actually connect and track the files. File mapping must be setup correctly too. If it's win localhost, DBGp's "Remote path" and "Local path" settings should be the same string, as remote path is meant as what the apache process sees, and on Windows machine's localhost is sees the same thing as npp. If the mapping is set incorrectly check the "Use SOURCE ..." Xdebug will then send temporary file with source to npp everytime the page is debugged. If you'll see the highlighted line moving down when single stepping after checking that box you can be pretty sure have error in mapping defined.
You can check yourself in realtime whether the connection attempt from apache httpd is made to notepad++ with TCPview from SysInternals/Winternals. Google for it. Isn't Windows or other firewall blocking the connection? In this case Notepad++ is the "server" and Apache connects to it, so add npp to your fw exceptions.
I guess you have these setup correctly too:
zend_extension_ts=php_xdebug.dll
xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.idekey=default
When first trying this I experienced several glitches, but it runs flawlessly now even after several updates up to 5.0.2.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Ok now I can get the task bar button to flash. I used firefox rather then I.E. but I get a dialog box that says "Element does not contain a single text node" I click on that and back to the same Notepad ++ window with the debug window at the bottom and no debug toolbar buttons enabled.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Xdebug Not working with Notepad++ Not flashin (New)
By: Robert Davis (shaba1) - 2008-07-05 02:45
I set up notepad++ according to the instructions on the web site. I had already had xdebug set up in my php.ini file. I also followed the instruction at
http://www.judiwa.com/wiki/How_to_Setup_BDGp_debugger_in_Notepad%2B%2B_to_Debug_PHP
Everything worked fine until part where I am suppose to enter
http://localhost/debugTest.php. I acutally use http://127.0.0.1/Robin/debugTest.php becasue that is where I saved the file. Well notepad++ does not "flash" as the tutorial said it should, the step over, Step Into,Run,Stop, Step Out,Run To menu choices and buttons are all greyed out. In the debugger section at the bottom of the notepad++ window it says disconnected. I have done a netstat -a -b and notepad++ shows as listening on port 9000. I even opened that port on my linksys router just to be sure that was not blocking things. even though I am running notepad on the actual machine that the php file is saved to.
After all this debugging still does not start. Does anyone have a reason why.
P.S. Yes I have done a phpinfo.php and xdebug shows up as loaded and running. And yes I am using http://127.0.0.1/Robin/debugTest.php?XDEBUG_SESSION_START=test. Without the xdebug token that file runs just fine and gives the expected output.
Just to cover all the obvious causes.
Maybe it would be more helpful for everyone if you provided components versions. Even apache one.
When you use Xdebug it's Apache who is responsible for connecting to npp. Older version of DBGp client also had some problem with never versions of xdebug and was not understanding correctly some signals from apache/php/xdebug combo. You should upgrade at least Xdebug and DBGp client.
I use npp 5.0.2 as server with Xdebug 2.1.0-dev on Apache 2.2/PHP 5.2.5 as client and the debugging is triggered using Firefox 3 and Xdebug 0.3 Extension and besides slightly broken breakpoint management in DBGp 0.0.8.16 everything seems fine.
In your DBGp settings dialog, "idekey" must match the "idekey" defined in the Firefox extension or cookie to actually connect and track the files. File mapping must be setup correctly too. If it's win localhost, DBGp's "Remote path" and "Local path" settings should be the same string, as remote path is meant as what the apache process sees, and on Windows machine's localhost is sees the same thing as npp. If the mapping is set incorrectly check the "Use SOURCE ..." Xdebug will then send temporary file with source to npp everytime the page is debugged. If you'll see the highlighted line moving down when single stepping after checking that box you can be pretty sure have error in mapping defined.
You can check yourself in realtime whether the connection attempt from apache httpd is made to notepad++ with TCPview from SysInternals/Winternals. Google for it. Isn't Windows or other firewall blocking the connection? In this case Notepad++ is the "server" and Apache connects to it, so add npp to your fw exceptions.
I guess you have these setup correctly too:
zend_extension_ts=php_xdebug.dll
xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.idekey=default
When first trying this I experienced several glitches, but it runs flawlessly now even after several updates up to 5.0.2.
BUMP
bump again. Can someone even attempt to answer this.
Ok now I can get the task bar button to flash. I used firefox rather then I.E. but I get a dialog box that says "Element does not contain a single text node" I click on that and back to the same Notepad ++ window with the debug window at the bottom and no debug toolbar buttons enabled.