How to continue debugging?


I am used to NuSphere's phpED and this is how i debug:

1. open main index.php in docroot

2. select to debug that file

3. this opens internal (to the IDE) browser and opens website in that browser

4. click any link within the site and any breakpoint i have set will be hit

5. i can now stop debugging and make edits to code

--- after this is where things don't seem to work in Storm

6. click any link and debugging continues

IE - the debugger is listening to this browser session


as best i can tell in Storm i need to restart a new debugger session to start debugging again (and then redo navigation to the page i was testing). I am sure this isn't right and there must be something i am missing - anyone know what i did wrong?


Comment actions Permalink

Hi there,

How do you start debugging in PhpStorm?

If it's via Run/Debug Configuration (within the IDE) then it just adds the "debug me" parameter to the URL ... which AFAIK does not get carried out to the next page (as it's in current URL only).

You could use xdebug browser extension -- it works via cookies .. so such "debug me" flag is always present (until you remove it or it expires) and will survive page reload/form submission/link navigation and will also participate in ajax requests.

Alternative approaches:

  • configure xdebug (in php.ini) to debug every single request automatically
  • place "xdebug_break();" in your code (programmatic breakpoint -- will also initiate debug session)
Comment actions Permalink

As i said above, i start debugging by clicking DEBUG (little bug icon) inside the IDE.

Re: your suggestions:

1. browser extension - will check into this

2. config xdebug - seems like this would be awkward, but will to try it out - do you know setting required for this?

3. add code - not acceptable


Comment actions Permalink

thanks, i will take a look.

The browser extension does seem like the way to go though; but it doesn't work. I added extension and i see green bug in address bar and i set ext option to phpStorm - but breakpoints are not hit. Is there possibly something i need to configure in Storm to make this work?

Comment actions Permalink

ahhh.. the Phone icon.. yes, that's the missing piece. Thank you.


Please sign in to leave a comment.