Magento FirePHP extension

Featured Image

FirePHP is Firefox add-on that enables you to log to your Firebug Console, which makes it great debugging tool for any web developer. I’m using it, like it and can’t live without it for some time now ;) So here’s nicely packed Magento FirePHP extension, I believe you’ll be seeing it at Magento Connect in a while.

You can get it via file: magento-firephp-0.3.zip or even better, use Magento FirePHP Extension on Magento Connect.

Since FirePHP is implemented in Zend Framework it’s really easy to use it with Magento, my friend Branko wrote about it before.

Download FirePHP from its homepage www.firephp.org. You must have Firebug installed and the “Net” panel enabled to use it, and Firefox of course.

Extension needs to be enabled through Magento configuration and respects Allowed IPs option if used, which is great for tracing problems on live sites:

System->Configuration->Developer->Debug->FirePHP
System->Configuration->Developer->Developer Client Restrictions->Allowed IPs

After you enable FirePHP in Magento configuration you can start using it simple as

Mage::helper(‘firephp’)->send(‘Lorem ipsum sit amet ..’);
Mage::helper(‘firephp’)->debug(Mage::getModel(‘catalog/product’)->load(54));

Send function sends whatever you throw in it, while debug checks for Varien_Object instance and sends Varien_Object->debug() to console. If you’re dumping usual Magento objects, be sure to use debug.

We’re looking forward new FirePHP 1.0 announced for this year !!

Updated
0.0.3 – license change, Magento Connect release
0.0.2 – fixed compatibility problem in 1.3.2.x versions
0.0.1 – initial release

Interested in hiring us?

Have a chat with us. You would be surprised how small changes can make your business even more successful.


About Ivan Weiler

Technical Educator and Consultant

Ivan is a Technical Educator and Consultant. He gained lots of experience managing some of the most complex Magento projects we had at Inchoo.

Read more posts by Ivan / Visit Ivan's profile

29 comments

  1. Great plugin. Installed in seconds on 1.7. Exceedingly superior to alternative debug solutions. Would love to contribute to development of the plugin if you have any interest.

  2. Thanks, this looks good! I am able to “Hello world” but can someone provide more example of using it with firebug please? Anything… for example how would one control styling of console (error, warning, etc..). Can I rely on firephp documentation for the logging statements or is this totally different?

  3. I’m getting a 500 Internal Server Error on Model/Client.php file
    saying can’t find class ‘Mage’

    Any Ideas what might be the problem?

  4. Thanks, did that but apparently after activating the .net panel I had to restart Firefox. Now it works.

  5. Hi, I try to install firephp with Magento connect
    and i ve got this error (I’m using 1.5.0.1):

    community/Inchoo_Developer: No releases for 'Inchoo_Developer', skipping

    Do i miss something ?
    I’m new on magento but really great site so far !

  6. FYI this only happens when I try to pull up the object in the full array viewer NOT when I look at it in the console

  7. THIS IS A GREAT PLUGIN! However, every time I try to look at a Varien object in Magento (when I call $this) Firefox stops responding and crashes with it saying that the javascript isn’t responding. I am running Magento 1.3.3 and the latest version of this plugin.

    Thanks for all your hard work!

  8. hello,
    I am new to this but still tried to use firephp with magento but no success it would be great if you can make a step by step tutorial, that will be very helpful

    Thanks Alot

  9. Hello,

    I tried to install, strictly followed this tutorial. But when I put a :

    debug(‘Lorem ipsum sit amet ..’); ?>
    somewhere into my .phtml file (firephp enabled in admin). It doesn’t work.

    The only thing I didn’t do is the “Net Panel”, I don’t know what it is and I don’t know where to download it.

    Can you help me please ?

  10. Magento CE 1.3.2.4

    I just called it randomly in a custom .phtml file that calls in new products to a sidebar in order to test it.

  11. @evuska,Alan M: Could you please check and comment on which Magento versions are you getting this error and from where (which file) are you calling Mage::helper(‘firephp’).

    I wrote this extension some time ago and I’ve been using it on all newer 1.3 versions, 1.4 version and even on last two Enterprise versions.

    Older versions won’t be supported, but I’ll correct all errors :)

    Thanks

  12. Hi,

    I think the same, FirePHP is fantastic, a great tool for any web developer.
    I’d like to use your extension but I get the error: “Response objects not initialized” Could you help me? thanks!

  13. I gotta say this man. if anyone owes or develops magento stores, then it is a must-see for him/her to visit your blog.

Leave a Reply

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

You may use these HTML tags and attributes: <a href="" title=""> <blockquote cite=""> <code> <del datetime=""> <em> <strike> <strong>. You may use following syntax for source code: <pre><code>$current = "Inchoo";</code></pre>.