phpstormphpstorm-2017.2

PhpStorm - remove 200 responses from console when using built in PHP server


I am using PhpStorm and tried yesterday to use the built-in server functionality that it provides.

It works, but I find the console showing in bright red the 200 responses quite annoying, as it makes quite hard to spot real issues.

In the picture below you'll see what I mean.

enter image description here

Is there any way to disable these and only show for instance warnings (maybe in yellow) and errors (maybe in red)?


Solution

  • Use Grep Console plugin for this -- should do the job fine (does so in similar consoles).

    Based on your requirements it allows you to:

    Your marker here could be [200]: for successful responses -- this is a simple "match the exact text" pattern. If it does not work (e.g. because this text is in the middle of the string .. or because it looks like regex (as [] have special meaning in regex)) then just convert it into proper regex: .*\[200\]:.* -- something like that should do.


    Example of how it works:

    enter image description here

    The rule for that is highlighted (plain string as it's a very simple rule -- match exact string):

    enter image description here