7

I am using xDebug for a first time. Everything works well, but when I want to go on localhost/phpmyadmin it want to start debug (I don't have breakpoints here).

How can I disable it only for phpmyadmin?

My config:

[XDebug]
zend_extension = "C:\xampp\php\ext\php_xdebug.dll"
xdebug.profiler_append = 0
xdebug.profiler_enable = 1
xdebug.profiler_enable_trigger = 0
xdebug.profiler_output_dir = "C:\xampp\tmp"
xdebug.profiler_output_name = "cachegrind.out.%t-%s"
xdebug.remote_enable = on
xdebug.remote_handler = "dbgp"
xdebug.remote_host = localhost
xdebug.remote_port = 9000
xdebug.trace_output_dir = "C:\xampp\tmp"
xdebug.collect_return="0"

I am using XAMPP, PhpStorm.

LazyOne
  • 158,824
  • 45
  • 388
  • 391
Juraj Lúdik
  • 83
  • 1
  • 7

1 Answers1

13

You can just turn off the debug connection listener by going to Run > Stop Listening for PHP Debug Connections.

PHPStorm will then ignore any connections from Xdebug. When you want to debug something again simply go to Run > Start Listening for PHP Debug Connections and it'll work again.

You could also permanently ignore those files by using Skipped Paths:

  • Go to Preferences
  • Go to Languages & Frameworks > PHP > Debug > Skipped Paths
  • Click the '+' sign to open a browse dialog
  • Browse to the web root where the phpmyadmin folder is located and select that folder
  • Click OK and exit out of preferences

The debugger should now ignore scripts in that directory.

Daniel Waghorn
  • 2,997
  • 2
  • 20
  • 33
  • Thanks Daniel, i try this and it works good, but is there any configuration, which do it automaticly on phpmyadmin? – Juraj Lúdik Jul 28 '16 at 11:24
  • Check my edit, I've added about skipped paths which may be what you're looking for. – Daniel Waghorn Jul 28 '16 at 11:31
  • Thanks it works, but now it loading page 10s it si 5x slower. Is there any configuration or sometnig which slow my request on localhost/phpmyadmin? – Juraj Lúdik Jul 28 '16 at 11:53
  • The only thing I can think of that could kill performance would be the xdebug profiler, although it's worth a try giving everything a reboot i.e. apache and see if that helps. – Daniel Waghorn Jul 28 '16 at 11:56
  • it works, only when i accessing phpmyadmin for a first time, i don't know why, but when i want access page for a second time, i must wait longer(from 2s on 10s) i will be using your first advice. Thanks :) – Juraj Lúdik Jul 28 '16 at 12:20
  • I think you should also disable `Force break at first line when no path mapping specified` and `Force break at first line when a script is outside the project` – ttvd94 Aug 15 '21 at 12:15