本文整理汇总了PHP中plugins::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP plugins::__construct方法的具体用法?PHP plugins::__construct怎么用?PHP plugins::__construct使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类plugins
的用法示例。
在下文中一共展示了plugins::__construct方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
function __construct()
{
parent::__construct();
$this->registry = registry::getInstance();
$this->addAction('index_init', 'init');
$this->addAction('index_load', 'addToolbar');
}
示例2: __construct
public function __construct()
{
parent::__construct();
define('VALID_URL', '/^(http|https):\\/\\/[a-z0-9]+([\\-\\.]{1}[a-z0-9]+)*\\.[a-z]{2,5}((:[0-9]{1,5})?\\/.*)?$/i');
$this->addAction('index_includes', 'replaceFeed');
$this->addAction('feed_header', 'feedRedirect');
$this->addAction('admin_init_config', 'addControlPanelOption');
$this->addAction('admin_init', 'checkConfig');
}
示例3:
function __construct()
{
parent::__construct();
$this->registry = registry::getInstance();
if (!defined('GESHI_VERSION')) {
require_once Absolute_Path . "app/plugins/geshi/GeSHi.php";
}
$this->addAction('index_post_content', 'source_code_beautifier');
$this->addAction('admin_comments_content', 'comment_source_code_beautifier');
$this->addAction('index_comment_content', 'comment_source_code_beautifier');
}
示例4: __construct
public function __construct()
{
parent::__construct();
$this->cookie = cookie::getInstance();
if (!defined('GESHI_VERSION') and file_exists(Absolute_Path . "app/plugins/geshi/GeSHi.php")) {
require_once Absolute_Path . "app/plugins/geshi/GeSHi.php";
}
$this->addAction('index_comment_added', 'usersNotify');
$this->addAction('index_comment_added', 'adminNotify');
$this->addAction('comment_approbed', 'notify');
}
示例5: __construct
public function __construct()
{
parent::__construct($this->getClass());
// call the parent constructor (var: name)
global $config;
// get the site config
global $game;
// current game id
$this->tables = explode(',', $config['cosmos']['chats_table_' . $game]);
$this->tables_names = explode(',', $config['cosmos']['chats_names_' . $game]);
parent::setTitle('Chatlogger');
parent::setVersion(1.0);
if (count($this->tables) != count($this->tables_names)) {
parent::error('In your settings, there are not the same number of tables and table names listed.');
}
}
示例6: __construct
public function __construct()
{
parent::__construct();
$this->addAction('index_post_content', 'findPHPcode');
}