更轻松地查看 firePHP 输出的最佳实践
我已经用 ZF (http://www.christophdorn.com/Blog/2008/09/02/firephp-and-zend-framework-16/) 实现了 firePHP,它的工作方式就像一个魅力。然而,我现在注意到,我的应用程序正在增长,并且 firePHP 输出量也在增长,因此审查它变得越来越困难。对我来说,主要问题是只有 3 种颜色可用(蓝色表示信息,黄色表示警告,红色表示 CRIT),因此很难区分条目(特别是当没有任何错误并且整个输出为“蓝色”时) “ 基本上)。
你们如何让 firePHP 输出更易于阅读?
谢谢。
I've implemented firePHP with ZF (http://www.christophdorn.com/Blog/2008/09/02/firephp-and-zend-framework-16/) which works like a charm. However what I'm noticing now that my application is growing and that the amount of firePHP output grows is that it's beocming increasingly difficult to review it. The main issue for me is that there are only 3 colors available (blue for INFO, yellow for WARN, and red for CRIT) thus making difficult to distinguish entries (especially when there aren't any errors and that the whole output is "blue" basically).
What do you guys do to make your firePHP output easier to read?
Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
时间戳,很多时间戳;)
我真的很想知道这些错误在哪里以及何时出现:)
只显示重要的东西也没什么坏处。
另请参阅 FirePHP 伴侣
timestamps, lots of timestamps ;)
I realy like to know where and WHEN are all those bugs :)
It wont hurt to display only important things either.
Also look at FirePHP Companion
ZendFramework 附带的 FirePHP 实现有些限制。我建议使用
FirePHPCore 0.3 或 FirePHP 1.0 代替。记录数据的 ZF 组件可以更新为使用外部库。我们计划对 FirePHP 1.0 进行更新的 ZF 集成。
使用外部 FirePHP 库,有多种选项可以组织记录的消息以便于查看。
FirePHPCore 0.3:
$firephp->log('Message' ,'可选标签');
$firephp->group('测试组');
$firephp->group('Collapsed)和彩色组', array('Collapsed' => true, 'Color' => '#FF00FF'));
请参阅 API 参考了解更多信息。
FirePHP 1.0 + DeveloperCompanion:
$console->label('Label')->log($var);
$console- >group('name', 'Label')->log($var);
(彩色组很快就会再次可用)FirePHP::to('request') ->console('Console 1')->log($var);
请参阅 API 参考了解更多信息。
The FirePHP implementation shipped with ZendFramework is somewhat limited. I would recommend using
FirePHPCore 0.3 or FirePHP 1.0 instead. The ZF components that log data can be updated to use the external library instead. There are plans for an updated ZF integration for FirePHP 1.0.
Using the external FirePHP libraries, there are several options to organizing logged messages for easier review.
FirePHPCore 0.3:
$firephp->log('Message','Optional Label');
$firephp->group('Test Group');
$firephp->group('Collapsed and Colored Group', array('Collapsed' => true, 'Color' => '#FF00FF'));
See API reference for more information.
FirePHP 1.0 + DeveloperCompanion:
$console->label('Label')->log($var);
$console->group('name', 'Label')->log($var);
(colored groups will be available again soon)FirePHP::to('request')->console('Console 1')->log($var);
See API reference for more information.