本文整理汇总了PHP中Debugger::init方法的典型用法代码示例。如果您正苦于以下问题:PHP Debugger::init方法的具体用法?PHP Debugger::init怎么用?PHP Debugger::init使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Debugger
的用法示例。
在下文中一共展示了Debugger::init方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: defined
<?php
defined('SYSPATH') or die('No direct script access.');
// Render Debugger Toolbar on the end of application execution
if (Kohana::$config->load('debugger.register_shutdown_function') === true) {
Debugger::init();
register_shutdown_function(array('Debugger', 'shutdown'));
}
示例2: launch
/**
*
*
* @since 1.5
*/
public static function launch($loader_path)
{
if (self::$plugin) {
wp_die(__('Cheatin’ huh?'));
}
self::$plugin = new self($loader_path);
if (WP_DEBUG) {
include self::$plugin->dirPath . '/debugger/debugger.class.php';
self::$debugger = Debugger::init('SiteTree', self::$plugin->dirPath);
}
if (version_compare(get_bloginfo('version'), self::MIN_WP_VERSION, '<')) {
self::$plugin->registerFatalError(sprintf(__('To run %s you need at least WordPress %s. Please, update your WordPress installation to ' . 'the %slatest version%s available.', 'sitetree'), 'SiteTree', self::MIN_WP_VERSION, '<a href="http://wordpress.org/download/" target="_blank">', '</a>'));
add_action('plugins_loaded', array(self::$plugin, 'loadTextdomain'));
return -1;
}
global $pagenow;
switch ($pagenow) {
case 'wp-cron.php':
add_action('sitetree_ping', array(self::$plugin->pingController(), 'ping'));
// During cron we load the bare minimum, so all works faster.
return 2;
case 'plugins.php':
register_activation_hook($loader_path, array(self::$plugin, 'activate'));
}
add_action('init', array(self::$plugin, 'finishLaunching'));
}
示例3: date_default_timezone_set
<?php
date_default_timezone_set('UTC');
$debugger = __DIR__ . '/../vendor/crisu83/yii-debug/helpers/Debugger.php';
require_once $debugger;
Debugger::init(__DIR__ . '/../app/runtime/debug');
$yii = __DIR__ . '/../vendor/yiisoft/yii/framework/yii.php';
$global = __DIR__ . '/../app/helpers/global.php';
$builder = __DIR__ . '/../vendor/crisu83/yii-configbuilder/helpers/ConfigBuilder.php';
require_once $yii;
require_once $global;
require_once $builder;
$config = ConfigBuilder::buildForEnv(array(__DIR__ . '/../app/config/main.php', __DIR__ . '/../app/config/web.php', __DIR__ . '/../app/config/environments/{environment}.php', __DIR__ . '/../app/config/local.php'), __DIR__ . '/../app/runtime/environment');
Yii::createWebApplication($config)->run();