本文整理汇总了PHP中PageController::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP PageController::__construct方法的具体用法?PHP PageController::__construct怎么用?PHP PageController::__construct使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PageController
的用法示例。
在下文中一共展示了PageController::__construct方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
public function __construct()
{
parent::__construct();
$this->addPageData('header/assets/css', array('/admin-new/css/reset.css', '/admin-new/css/framework.css', '/admin-new/css/ui.visualized.css', '/admin-new/css/jquery.cluetip.css', '/admin-new/css/ui-coffee/ui.css'));
$this->addPageData('header/assets/js', array('/admin-new/js/jquery.js', '/admin-new/js/jquery.ui.js', '/admin-new/js/jquery.browser.js', '/admin-new/js/jquery.validator.js', '/admin-new/js/jquery.tablesorter.js', '/admin-new/js/jquery.tablesorter.pager.js', '/admin-new/js/jquery.dataTables.js', '/admin-new/js/jquery.daterangepicker.js', '/admin-new/js/jquery.form.js', '/admin-new/js/jquery.maskedinput.js', '/admin-new/js/jquery.corners.js', '/admin-new/js/jquery.hoverintent.js', '/admin-new/js/jquery.visualize.js', '/admin-new/js/jquery.autoupload.js', '/admin-new/js/jquery.qtip.js', '/admin-new/js/general.js', '/admin-new/js/messagestack.js'));
$this->member = Config::get('Member');
}
示例2: __construct
public function __construct()
{
if (!$this->displayName) {
$this->displayName = 'Login Form';
}
parent::__construct();
}
示例3: __construct
public function __construct()
{
parent::__construct();
global $container;
$this->activityRepository = new Jacobemerick\Web\Domain\Stream\Activity\MysqlActivityRepository($container['db_connection_locator']);
}
示例4: __construct
public function __construct()
{
Auth::requireAdmin();
if (!$this->displayName) {
$this->displayName = 'Manage Images';
}
parent::__construct();
}
示例5: __construct
/**
* Constructor of this class.
* It initializes some class variables used to display the right product types.
*/
public function __construct($titleKey, $class, $type, $limit = 0)
{
$this->class = $class === ProductType::CLASS_UNKNOWN ? null : $class;
$this->type = $type === ProductType::TYPE_UNKNOWN ? null : $type;
$this->limit = $limit;
$this->id = null;
$view = new ProductView($titleKey, Template::PRODUCT_SECTION, new ProductModel());
parent::__construct($view);
}
示例6: __construct
/**
* __construct
*
* PageController constructor
*
* @param string $template
*/
public function __construct($template = null, $post_type = null)
{
$this->post_type = $post_type ? $post_type : get_post_type();
if (!$template) {
// try to guess the view for custom post types
$template = sprintf("single%s.twig", $this->post_type === 'post' ? '' : "-{$this->post_type}");
}
parent::__construct(array($template, 'single.twig'));
}
示例7:
/**
* Construct cron controller
*
* @param Request $request
* @return null
*/
function __construct($request)
{
parent::__construct($request);
if (defined('PROTECT_SCHEDULED_TASKS') && PROTECT_SCHEDULED_TASKS) {
$code = $this->request->get('code');
if (empty($code) || strtoupper($code) != strtoupper(substr(LICENSE_KEY, 0, 5))) {
$this->httpError(HTTP_ERR_FORBIDDEN);
}
// if
}
// if
}
示例8: __construct
public function __construct()
{
Auth::requireAdmin();
if (!$this->noun) {
$this->noun = preg_replace('/^.+\\\\/', '', $this->entity);
}
if (!$this->nounPlural) {
$this->nounPlural = $this->noun . 's';
}
if (!$this->displayName) {
$this->displayName = 'Manage ' . $this->nounPlural;
}
parent::__construct();
}
示例9: __construct
/**
* Constructor
* Set up configuration containers
* Start session handling
* Setup error processing and email
* @SuppressWarnings(PHPMD.ExitExpression)
*/
public function __construct()
{
parent::__construct();
$this->_previewMode = false;
if ($this->_config->getMode() == 'MAINTENANCE') {
$request = new \Lvc_Request();
$request->setControllerName('maintenance');
$request->setActionName('index');
// Get a new front controller without any routers, and have it process our handmade request.
$frontController = new \Lvc_FrontController();
$frontController->processRequest($request);
exit;
}
$this->setupSession();
$this->setupDoctrine();
}
示例10:
/**
* Construct the controller
*
* @param void
* @return FeedController
*/
function __construct()
{
parent::__construct();
$this->setLayout('xml');
// default layout for this controller
}
示例11: __construct
public function __construct()
{
$view = new ShippingView(Template::SHIPPING, new ShippingModel());
parent::__construct($view);
}
示例12: __construct
public function __construct()
{
parent::__construct();
$this->jsFiles['results.js'] = array('results.js');
$this->cssFiles['results.css'] = array('results.css');
}
示例13: __construct
public function __construct()
{
$view = new RegisterView(Template::REGISTER, null);
parent::__construct($view);
}
示例14:
/**
* Construct the ErrorController
*
* @access public
* @param void
* @return ErrorController
*/
function __construct()
{
parent::__construct();
$this->addHelper('form', 'breadcrumbs', 'pageactions', 'tabbednavigation', 'company_website', 'project_website');
}
示例15: __construct
public function __construct()
{
$view = new OrderView(Template::ORDER, null);
parent::__construct($view);
}