FirePHP table variable view

3 messages Options
Embed this post
Permalink
radalin () FirePHP table variable view
Reply Threaded More More options
Print post
Permalink
Hi,

I ws playing with Zend Framework's Firebug profiler recently and had encountered an issue about table element used by the firephp.

When I was trying to create a table which I was intending to show up some variable, I found that variable view was only shown for the array type of variables. When I passed an ArrayObject to it it was just a plain text and not a variable.

It would be great to see a real variable view. It could be something like a type of a cell. When it's set you could be able to see the current variable's properties via a var_dump or something like that.

This might also be useful for xdebug viewing too. This could be an easy alternative and not that much of development feature by this way.

(Instead of calling xdebug_break() call my_xdebug_break() and in this function it will call the xdebug_break() after it has sent some information to the firephp log, maybe stack logs or variable values etc. This really might be usefull)

thanks
radalin () Re: FirePHP table variable view
Reply Threaded More More options
Print post
Permalink
Hi,

I checked around the code for a bit. And the problem about the ArrayObject seems to that it does not have an actual json encoding presentation (but it has the same presentation as array as I checked. But I guess that's a thing about all serialized objects may not be unserialized properly).

While Firephp sends it's message to the console, it parses the current message to a json string and if you send an ArrayObject or a custom php class of your own, it won't be parsed to a meaningful json string. and it will be executed as a string (also your custom class will not be parsed at all) and variable view won't appear.

So I guess it's not really possible to solve this problem without using a var_dump($foo) and then pass it to the message so that it will be at least seen as a string.

I would welcome some suggestions and I'm eager to work for this solution to work by the way (but I guess this one includes some custom json encodings and decodings which I don't think it's really a good idea). Maybe this can also be opened as an issue to the Zend Framework too but I dunno.
Christoph Dorn () Re: FirePHP table variable view
Reply Threaded More More options
Print post
Permalink
Please open a ticket in the issue tracker and provide a test case. Include a mockup or simple but specific information about what should be displayed.