Here are the few simple steps to follow:
Get the ChromePhp.php file from here. Include the file in your project by using autoloader or inlcude_once() feel free to use the method you like.
Note: If you want to use it with Laravel, simply keep the file in your helper or lib directory (the directory where you keep your own helper classes or functions) and all is done.
You’ll see an icon on the top right of your Chrome browser like ‘cmd’ icon for Window. Click this icon to activate, it will lighten up blue. Now, you are ready to log your variables or whatever you want in the Console tab of your Chrome browser. Here are a couple of examples:
ChromePhp::log('Hello console log'); ChromePhp::info('Hello console info'); ChromePhp::warn('Hello console warn');
Note: You can also write your logs to Console tab of Chrome no matter what language you are using. This post was for PHP but you can use it using Perl, Python, Ruby, Jave, .Net and other languages as well. Follow instructions on the link and enjoy easy debugging using Console tab of Chrome.