當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Base::init方法代碼示例

本文整理匯總了PHP中Base::init方法的典型用法代碼示例。如果您正苦於以下問題:PHP Base::init方法的具體用法?PHP Base::init怎麽用?PHP Base::init使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Base的用法示例。


在下文中一共展示了Base::init方法的13個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: init

 protected function init()
 {
     parent::init();
     $log = $this->getLog();
     $log->add("\n\n-----------------------Hello world service----------------------------");
     $log->flush();
 }
開發者ID:ZhuJingfa,項目名稱:HuiLib,代碼行數:7,代碼來源:SampleModule.php

示例2: init

 public function init()
 {
     parent::init();
     if (!$this->refine) {
         $this->refine = [$this, 'refine'];
     }
 }
開發者ID:pahanini,項目名稱:yii2-refiner,代碼行數:7,代碼來源:Match.php

示例3: init

 public function init()
 {
     parent::init();
     $this->tempFile = tempnam($this->tempPath, 'php-auto-update-');
     $this->archive = new \ZipArchive();
     $this->createZipFile();
 }
開發者ID:sam-it,項目名稱:php-auto-update,代碼行數:7,代碼來源:Update.php

示例4: init

 /**
  * init 
  * 
  * @return void
  */
 public function init()
 {
     parent::init();
     $this->removeElement('userId');
     $this->getElement('submit')->setLabel($this->translate('register'));
     //$this->removeElement('role');
 }
開發者ID:GeeH,項目名稱:zf2-sandbox,代碼行數:12,代碼來源:Register.php

示例5: init

 protected function init()
 {
     parent::init();
     if (! file_exists($this->http_load)) {
         $this->outln("File not found: '{$this->http_load}'.");
         exit(1);
     }
 }
開發者ID:pmjones,項目名稱:php-framework-benchmarks,代碼行數:8,代碼來源:HttpLoad.php

示例6: init

 public function init()
 {
     parent::init();
     $this->addElement('text', 'title', array('required' => true, 'validators' => array(array('NotEmpty', true, array('messages' => 'Titre obligatoire'))), 'attribs' => array('class' => 'text medium')));
     $this->addElement('textarea', 'text', array('required' => true, 'validators' => array(array('NotEmpty', true, array('messages' => 'Contenu obligatoire'))), 'attribs' => array('class' => 'wysiwyg')));
     $this->addElement('hidden', 'filename', array('required' => true, 'validators' => array(array('UploadExists', true, array('messages' => 'Aperçu incorrect')), array('NotEmpty', true, array('messages' => 'Image obligatoire')))));
     $this->getElement('filename')->setDecorators(array(array('ViewScript', array('viewScript' => '_upload.phtml'))));
     $this->defaultFilters();
 }
開發者ID:nicolas-brousse,項目名稱:lightMonitor,代碼行數:9,代碼來源:Setting_Server_Form.php

示例7: init

 /** @inheritdoc */
 public function init()
 {
     parent::init();
     if ($this->envFolder === null) {
         $this->envFolder = realpath(__DIR__ . '/../../environments');
     }
     if (!is_array($this->envDescription)) {
         $this->envDescription = [];
     }
 }
開發者ID:ekup,項目名稱:yii2-installer,代碼行數:11,代碼來源:CreateStructure.php

示例8: init

 public function init()
 {
     parent::init();
     $this->sourceHash = $this->git('rev-parse', ['--verify', $this->source . '^{commit}']);
     $this->targetHash = $this->git('rev-parse', ['--verify', $this->target . '^{commit}']);
     if (!isset($this->sourceHash) || !isset($this->targetHash)) {
         throw new \Exception("Source or target commit not found.");
     }
     $this->initChanges();
 }
開發者ID:sam-it,項目名稱:php-auto-update,代碼行數:10,代碼來源:Git.php

示例9: define

<?php

define('DEBUG', 1);
define('PATH', dirname(__FILE__));
require_once PATH . '/app/Core/autoload.php';
Base::init();
開發者ID:nytr0gen,項目名稱:plur-music-explorer,代碼行數:6,代碼來源:index.php

示例10:

<?php

/*
Plugin Name: WP Plugin Base
Plugin URI: http://khaledsaikat.com
Description: Base files for creating new WordPress plugin
Author: Khaled Hossain
Version: 1.0-alpha
Author URI: http://khaledsaikat.com
*/
namespace PluginBase;

require __DIR__ . '/vendor/autoload.php';
Base::init(__FILE__);
Base::load_controllers();
開發者ID:khaledsaikat,項目名稱:wp-plugin-base,代碼行數:15,代碼來源:init.php

示例11: init

 protected function init($account)
 {
     parent::init($account);
     $this->accumulator = 0;
 }
開發者ID:jschaedl,項目名稱:bav,代碼行數:5,代碼來源:Iteration.php

示例12: init

 function init()
 {
     parent::init();
     $this->uid = cookie('adminUid');
     $this->uname = cookie('adminUser');
 }
開發者ID:sunkangtaichi,項目名稱:PHPAPPLISTION_START,代碼行數:6,代碼來源:Login.php

示例13: shortcodes_to_exempt_from_wptexturize

<?php

require_once get_template_directory() . '/base/base.php';
require_once get_template_directory() . '/base/custom/config.php';
$theme = new Base();
$theme->init($theme_config);
add_filter('no_texturize_shortcodes', 'shortcodes_to_exempt_from_wptexturize');
function shortcodes_to_exempt_from_wptexturize($shortcodes)
{
    $shortcodes[] = 'accordions';
    $shortcodes[] = 'tabs';
    return $shortcodes;
}
開發者ID:ahoymehearties,項目名稱:responsiblegamer,代碼行數:13,代碼來源:functions.php


注:本文中的Base::init方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。