Debugging in Php

I can’t seem to get my php_debug.dll to load on a windows 7 machine. Here’s the relevant portion of my php.ini, the one that php_info says is loaded:

; xdebug config for Windows
zend_extension_ts="C:\Program Files (x86)\PHP\v5.6\ext\php_xdebug.dll" 
;zend_extensions=C:\Program Files (x86)\PHP\v5.6\ext\php_xdebug.dll 
xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.remote_host=127.0.0.1
xdebug.remote_port=9000
xdebug.idekey=pdryden
xdebug.remote_autostart=1

I’ve tried enabling both lines for zend_extension, using quotes or not around the path and not in any case does php_info have any xdebug section.
I’ve even created a short C++ app that where LoadLibrary called on the same path is successful.

I am using komodo ide 8.5.

What am I doing wrong here?

Hi @pdryden94.

Are you sure you’re using the right php.ini file? The php.ini file that php is using should show up in the output of phpinfo().

Are you doing “remote” or “local” debugging, eg. are you debugging from a process started from the Browser or are you debugging from a process started in Komodo?

  • Carey

Are you sure you’re using the right php.ini file? The php.ini file that php is using should show up in the output of phpinfo()
-> I copied the path for the ini file from the output of phpinfo()

I’m using remote debugging, but that’s not really relevant because if php_xdebug isn’t loaded (as evidenced by the lack of any information on it being found in phpinfo()) debugging isn’t going to work.

Copied it and put it where?

This is definitely relevant. Local debugging you configure in Komodo. Remote you configure outside of Komodo. Remote debugging has nothing to do with Komodo until the process is started and it contacts Komodo to start a debugging session.

I THINK what is going on is that you’re trying to configure remote debugging from within Komodo which is not correct. With out more information of exactly what you’ve done though I can’t be sure. Have a quick look through the docs to see if that helps you to find what you missed: http://docs.komodoide.com/Manual/debugphp#debugging-php-komodo-ide-only_remote-php-debugging

  • Carey

careyh,

thanks for all the help. I expected to be ignored.

Where did I put the the path of the ini file copied from the output of phpinfo()?
Into the open file dialog of Komodo IDE 8.5.

I believe I’m following the instructions in the link you provided. This isn’t the first time I’ve set up Komodo for remote debugging, I have a new computer (64 bit) and it’s not working on it. I have a very similar setup on another machine (Server 2008) that works fine. Is there a way to trace the loading of extensions in php to help figure out why php_xdebug.dll won’t load?

Thanks again.

careyh,

I found the problem.
in the ini file I had a stray s in the line:

incorrect

zend_extensions=D:\php-sdk\php_xdebug-2.3.3-5.6-vc11-nts.dll

correct:

zend_extension=D:\php-sdk\php_xdebug-2.3.3-5.6-vc11-nts.dll

BAH. I hate those. Glad you got it. @pdryden94.

Never ever…well maybe…sometimes we’re crazy busy. Usually you’ll get a response within the day though. That’s not to say your issue will be resolved that quick :wink:

  • Carey

I just wonder how the extra s got there. Deleting the _ts in “zend_extension_ts” and missing the “s”, or copying from another website that had the extra “s” already there. Water under the bridge. Thanks again for the help.