how to get PHP chrome-logger working in laravel?

I want to be able to send debugging statements to the browser console from laravel php files. I’ve learned this is possible from here:

https://craig.is/writing/chrome-logger

I follow instructions but can’t get it to work. I’ve installed the chrome extension and have the icon turned on (blue) on the web page. I have the following line within a while loop where I want to show each line of a file that is being read, like this:

ChromePhp::log($line);

The instructions for PHP version of the logger are here:

https://github.com/ccampbell/chromephp

It says to put ChromePhp.php “in the php path” but neglects to explain where that might be. So I leave it out to see what kind of error message it will provide. The error says

Class ‘AppHttpControllersChromePhp’ not found

Ah ha, so that’s where it needs to go. So I stick it there and try again…
Same error.

Anybody get this to work?

Source: Symfony Questions

Was this helpful?

0 / 0

Leave a Reply 0

Your email address will not be published. Required fields are marked *