asenar/chromephp 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

asenar/chromephp

最新稳定版本:5.0.0

Composer 安装命令:

composer require asenar/chromephp

包简介

Log variables to the Chrome console (via Chrome Logger Google Chrome extension).

关键字:

README 文档

README

ChromePhp is a PHP library to log variables to the Chrome or Firefox devtools console. For Google Chrome the Chrome Logger extension is needed.

Requirements

  • PHP 5 or later

Installation Chrome

  1. Install the Chrome extension from: https://chrome.google.com/extensions/detail/noaneddfkdjfnfdakjjmocngnfkfehhd

  2. Click the extension icon in the browser to enable it for the current tab's domain

  3. Put ChromePhp.php somewhere in your PHP include path

  4. Log some data

    include 'ChromePhp.php';
    ChromePhp::log('Hello console!');
    ChromePhp::log($_SERVER);
    ChromePhp::warn('something went wrong!');

Installation Firefox

  1. Put ChromePhp.php somewhere in your PHP include path

  2. Enable Server logging filter in the web console

  3. Initialize ChromePhp for FirePHP compatibility

    include 'ChromePhp.php';
    $firephp = ChromePhp::getInstance();
    $firephp->setEnabled(true, 'FirePHP');

    The second parameter 'FirePHP' is optional and can be omitted in subsequent calls to setEnabled. FirePHP compatibility mode can be changed by calling

    // disable FirePHP mode
    $firephp->addSetting('log_style', '');
    
    //enable FirePHP mode
    $firephp->addSetting('log_style', 'FirePHP');
  4. Log some data

    $firephp->log($_GET, 'GET variables');
    $firephp->warn('Value out of range');

More information can be found here:

http://www.chromelogger.com

https://developer.mozilla.org/en-US/docs/Tools/Web_Console/Console_messages#Server

统计信息

  • 总下载量: 19.21k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 442
  • 开发语言: PHP

其他信息

  • 授权协议: Apache-2.0
  • 更新时间: 2017-02-22