FireLogger is a Firefox+Firebug addon which provides logging functionality similar to Firebug’s console.log. It sends logging events to a client-side encoded in HTTP headers.
I always really liked an idea of debugging through headers, mostly because you are able to log directly to Firebug and it makes debugging of live sites invisible. I came across this tool by searching for Firephp alternatives, since Firephp never could properly handle redirection logging and I believe latest Companion versions are overcomplicated.
This tool comes from Python world originally, it seems that it was called FirePython at start?! Anyway, I was testing it for a few days and it really works great, it’s stable and easy to use, complements to the author.
You can install it from official or Firefox addon page and it requires Firebug to work:
The tool adds another tab in Firebug named Logger in which you can see logs sent from code. If you’re dumping objects or arrays, you just click “more” and variables are shown in right Watchers window. If you click Persist button, logs stays there on redirect/reload, similar as Net functionality in Firebug.
For some reason, current 1.0 version didn’t worked on FF 3.X versions for me, it seems FF 4.X is required. Also, be sure that “Show User-defined properties” is checked on Watchers tab (check screenshot), otherwise you won’t see variables when clicking more in logger window.
Php library is well written, there is only one file you need to include in your projects and you’re good to go. It requires PHP 5.3 or higher and it’s nice example of register_shutdown_function usage.
require 'firelogger.php'; flog("Hello world!");
Here is simple example I patched up together for testing purposes, to check how it works in Magento, maybe someone is interested: Weiler_FireLogger_example.zip
Mage::helper('firelogger')->log('Hello world!'); $product = Mage::getModel('catalog/product')->load(100); Mage::helper('firelogger')->debug($product);