How can I debug PHP in IIS? How can I debug PHP in IIS? wordpress wordpress

How can I debug PHP in IIS?


XDebug is a very very good tool for debugging PHP.

If you are using an IDE like Netbeans, XDebug allows you to run your PHP code on a local server in step-through mode, with break points and variable watches. Very very powerful and extremely easy to use.


I would suggest doing a phpinfo() and pasting the output here that's XDebug a very good debugger with Windows binaries on their site. Now whatever editor you're using needs to support xdebug in order to have that step-by-step thing.

Also you should look at FirePHP which is a plug-in for Firebug in Firefox. It's sort of in between the print_r(); and xdebug or...

Finally look at dbg which will also work on windows. In this post there is some configuration information for IIS, just ignore the stuff about VS.php.

Hope all that helps.


I've debugged alot of PHP on windows and never had that much of a problem, it would help to know what you are trying to use to debug things and what errors you are running into. Generally the errors you might have are stuff to do with Apache functions and/or presumptions made about $_SERVER[].

Anyhow, given FastCGI likely isn't the problem, I would setup the dev environment to run as normal CGI which should be a bit easier for the debugger to access.