-2

I cannot debug Laravel via PhpStorm and Xdebug.

When I try to debug a single file via PhpStorm, it works fine, but when I set a breakpoint and try it on the browser, it doesn't work.

PhpStorm waits for incoming connection with ide key and it stops there.

5
  • Can you provide some more information? Maybe some logs? Commented Apr 9, 2015 at 1:02
  • 2 sentence 19 words - does not a good question make Commented Apr 9, 2015 at 1:14
  • Im not getting logs at all. Just stucked. When I debug a single file it works perfect but when I try to debug laravel app via web application it stuck on waiting for incoming connection Commented Apr 9, 2015 at 1:20
  • Collect xdebug logs for such unsuccessful session and share here: xdebug.org/docs/all_settings#remote_log Commented Apr 9, 2015 at 8:36
  • As I understand, he wants to debug his code on browser but doesn't know how to. Commented Apr 9, 2015 at 14:50

1 Answer 1

0

The workflow that I've set:

  1. Use something like Xdebug helper.
  2. Configure it to use PhpStorm IDE Key.

When you want to debug:

  1. Activate Xdebug Helper (Mark Debug)
  2. Go to PhpStorm and Run > Start listening for PHP Debug Connections
  3. Put a breakpoint at your code
  4. Refresh your page in Chrome (or go to another one, just make a request).

Basically, the Xdebug Helper will be your trigger. If you disable it, PhpStorm no longer will debug your code.


If you don't want to relay on an extension, you can go to your Xdebug config and set:

xdebug.idekey=PHPSTORM
xdebug.remote_autostart=1

And "Start listening for PHP Debug Connections" will be your trigger.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.