当前位置: 首页>>代码示例>>PHP>>正文


PHP AppController::__construct方法代码示例

本文整理汇总了PHP中AppController::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP AppController::__construct方法的具体用法?PHP AppController::__construct怎么用?PHP AppController::__construct使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在AppController的用法示例。


在下文中一共展示了AppController::__construct方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: __construct

 public function __construct()
 {
     parent::__construct();
     $this->layout = 'painel';
     $this->Funcionario = new Funcionario();
     $this->Endereco = new Endereco();
 }
开发者ID:brunoblauzius,项目名称:sistema,代码行数:7,代码来源:EnderecosController.php

示例2: __construct

 /**
  * __construct
  *
  * @param CakeRequest $request
  * @param CakeResponse $response
  */
 public function __construct($request = null, $response = null)
 {
     parent::__construct($request, $response);
     $this->constructClasses();
     $this->Components->trigger('initialize', array(&$this));
     $this->_set(array('cacheAction' => false, 'viewPath' => 'Errors'));
 }
开发者ID:eboominathan,项目名称:Basic-CRUD-in-CakePHP-,代码行数:13,代码来源:CakeErrorController.php

示例3: __construct

 public function __construct()
 {
     parent::__construct();
     add_filter('wp_edit_nav_menu_walker', array(&$this, 'addMenuEditWalker'), 10, 2);
     add_action('wp_update_nav_menu_item', array(&$this, 'beforeSave'), 10, 3);
     add_filter('wp_setup_nav_menu_item', array(&$this, 'afterFind'));
 }
开发者ID:nikolaskarica,项目名称:bds-alliance,代码行数:7,代码来源:menus_controller.php

示例4: __construct

 public function __construct()
 {
     parent::__construct();
     $this->layout = "painel";
     $this->Mesa = new Mesa();
     $this->Ambiente = new Ambiente();
 }
开发者ID:brunoblauzius,项目名称:sistema,代码行数:7,代码来源:MesasController.php

示例5: __construct

 public function __construct()
 {
     $this->safeFunctionsU = array('chat');
     $this->safeFunctions = array('chat', 'preferences', 'password', 'notifications', 'users_data');
     parent::__construct();
     $this->cfg['title'] = $this->lang->line('Gestión');
 }
开发者ID:juanazareno,项目名称:nz,代码行数:7,代码来源:manager.php

示例6: Subjects

 function __construct()
 {
     parent::__construct();
     $this->subjects = new Subjects();
     $this->requirements = new GarantRequirements();
     $this->helpLink = HELP_COMMON;
 }
开发者ID:jankvak,项目名称:Schedule-of-pain,代码行数:7,代码来源:requirements.php

示例7: __construct

 /**
  * Constructor.
  *
  * @param Zend_Controller_Request_Abstract $request
  * @param Zend_Controller_Response_Abstract $response
  * @param array $invokeArgs
  * @throws Zend_Exception
  */
 public function __construct(Zend_Controller_Request_Abstract $request, Zend_Controller_Response_Abstract $response, array $invokeArgs = array())
 {
     parent::__construct($request, $response, $invokeArgs);
     $this->loadModuleElements();
     if (is_null($this->moduleName)) {
         throw new Zend_Exception('Please set the module name in AppController');
     }
     $fc = Zend_Controller_Front::getInstance();
     $this->view->moduleWebroot = $fc->getBaseUrl() . '/modules/' . $this->moduleName;
     $this->view->moduleName = $this->moduleName;
     if (file_exists(BASE_PATH . '/modules/' . $this->moduleName . '/configs/module.ini')) {
         $config = new Zend_Config_Ini(BASE_PATH . '/modules/' . $this->moduleName . '/configs/module.ini', 'global', true);
     } elseif (file_exists(BASE_PATH . '/privateModules/' . $this->moduleName . '/configs/module.ini')) {
         $config = new Zend_Config_Ini(BASE_PATH . '/privateModules/' . $this->moduleName . '/configs/module.ini', 'global', true);
     } else {
         throw new Zend_Exception('Unable to find configuration file');
     }
     $this->view->moduleFullName = $config->fullname;
     $this->view->moduleDescription = $config->description;
     // Add variables to the view that allow the retrieval of any enabled module
     // webroots
     $allModules = Zend_Registry::get('modulesEnable');
     foreach ($allModules as &$mod) {
         $modWebroot = $mod . 'Webroot';
         $this->view->{$modWebroot} = $fc->getBaseUrl() . '/modules/' . $mod;
     }
 }
开发者ID:josephsnyder,项目名称:Midas,代码行数:35,代码来源:GlobalModule.php

示例8:

 function __construct()
 {
     $this->name = 'search';
     $this->versioning = true;
     $this->base_view_dir = ROOT_DIR;
     parent::__construct();
 }
开发者ID:nonfiction,项目名称:nterchange,代码行数:7,代码来源:search_controller.php

示例9: __construct

 public function __construct()
 {
     parent::__construct();
     $this->layout = 'painel';
     $this->Email = new Email();
     $this->Email->useTable = 'emails_sistema';
 }
开发者ID:brunoblauzius,项目名称:sistema,代码行数:7,代码来源:EmailsController.php

示例10: __construct

 public function __construct()
 {
     $this->safeFunctionsU = array();
     $this->safeFunctions = array('data');
     parent::__construct();
     $this->cfg['title'] = $this->lang->line('Productos');
 }
开发者ID:juanazareno,项目名称:ananagulo,代码行数:7,代码来源:products.php

示例11: __construct

 public function __construct()
 {
     parent::__construct();
     $this->layout = "painel";
     $this->Ambiente = new Ambiente();
     $this->Salao = new Salao();
 }
开发者ID:brunoblauzius,项目名称:sistema,代码行数:7,代码来源:AmbientesController.php

示例12: __construct

 public function __construct($default = array())
 {
     parent::__construct($default);
     // set table
     $this->table = $this->app->table->account;
     // get application
     $this->application = $this->app->zoo->getApplication();
     // get Joomla application
     $this->joomla = $this->app->system->application;
     // get params
     $this->params = $this->joomla->getParams();
     // get pathway
     $this->pathway = $this->joomla->getPathway();
     // set base url
     $this->baseurl = $this->app->link(array('controller' => $this->controller), false);
     $this->cUser = $this->app->storeuser->get();
     $this->cart = $this->app->cart;
     // registers tasks
     $this->registerTask('customer', 'display');
     $this->registerTask('payment', 'display');
     $this->registerTask('confirm', 'display');
     $this->registerTask('save', 'display');
     $this->registerTask('processPayment', 'display');
     $this->registerTask('addCoupon', 'display');
     $this->registerTask('orderNotification', 'orderNotification');
     // $this->taskMap['display'] = null;
     // $this->taskMap['__default'] = null;
 }
开发者ID:camigreen,项目名称:ttop,代码行数:28,代码来源:checkout.php

示例13: __construct

 public function __construct()
 {
     parent::__construct();
     $this->css = array();
     $this->js = array();
     $this->User = new Usuario();
 }
开发者ID:brunoblauzius,项目名称:sistema,代码行数:7,代码来源:PagesController.php

示例14: __construct

 public function __construct()
 {
     $this->ClasseAllow = array('ajustaCadastros');
     parent::__construct();
     $this->layout = 'painel';
     $this->Cliente = new Cliente();
 }
开发者ID:brunoblauzius,项目名称:sistema,代码行数:7,代码来源:ClientesController.php

示例15: __construct

 /**
  * @param array $app
  * @param array $config
  * @throws AppException
  */
 public function __construct($app, $config = array())
 {
     parent::__construct($app, $config);
     $this->_jbrequest = $this->app->jbrequest;
     $task = $this->_jbrequest->getWord('task');
     $ctrl = $this->_jbrequest->getCtrl();
     if (!method_exists($this, $task)) {
         throw new AppException('Action method not found!  ' . $ctrl . ' :: ' . $task . '()');
     }
     // internal vars
     $this->application = $this->app->zoo->getApplication();
     $this->_params = $this->application->getParams('frontpage');
     $this->joomla = $this->app->system->application;
     $isSite = $this->app->jbenv->isSite();
     if (!$isSite) {
         $this->app->document->addStylesheet("root:administrator/templates/system/css/system.css");
         $this->app->jbassets->uikit(true, true);
         $this->_setToolbarTitle();
     } else {
         $this->params = $this->joomla->getParams();
         $this->pathway = $this->joomla->getPathway();
         $this->app->jbassets->setAppCSS();
         $this->app->jbassets->setAppJS();
     }
     $this->_config = JBModelConfig::model();
 }
开发者ID:alexmixaylov,项目名称:real,代码行数:31,代码来源:base.php


注:本文中的AppController::__construct方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。