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


PHP Public_Controller::__construct方法代码示例

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


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

示例1: __construct

 /**
  * Every time this controller is called should:
  */
 public function __construct()
 {
     parent::__construct();
     $this->lang->load("home");
     $this->config->load("tdesign");
     $this->load->helper(array("currency", "tdesign"));
 }
开发者ID:nockout,项目名称:tshpro,代码行数:10,代码来源:home.php

示例2: __construct

    public function  __construct()
    {
        parent::__construct();
        
        $this->load->model('shop_cat_m');
        $this->load->model('shop_items_m');
        $this->load->model('cart_m');
        $this->load->model('galleries/galleries_m');
        $this->load->model('galleries/gallery_images_m');
        $this->lang->load('shop'); 
        $this->load->library('cart');
        $this->load->library('form_validation');

        $this->cart_validation_rules = array(
            array(
                'field' => 'qty[]',
                'label' => 'lang:shop.qty_label',
                'rules' => 'trim|required|numeric'
            ),
            array(
                'field' => 'rowid[]',
                'label' => 'hidden',
                'rules' => 'required'
            )
        );

        $this->add_to_cart_rules = array(
            array(
                'field' => 'item_options[]',
                'label' => 'lang:shop.item_options_label',
                'rules' => 'trim'
            )
        );
    }
开发者ID:JamieLomas,项目名称:pyrocms-shop,代码行数:34,代码来源:shop.php

示例3:

 function __construct()
 {
     parent::__construct();
     $this->folder = "admin/";
     $this->module = $this->folder . "error/";
     $this->http_ref = base_url() . $this->module;
 }
开发者ID:TrinataBhayanaka,项目名称:damkar,代码行数:7,代码来源:error.php

示例4: __construct

 public function __construct()
 {
     parent::__construct();
     $this->load->model('newsletters_m');
     $this->load->model('subscribers_m');
     $this->lang->load('newsletter');
 }
开发者ID:phonglanpls,项目名称:jz-proj-2012,代码行数:7,代码来源:newsletters.php

示例5: __construct

 public function __construct()
 {
     parent::__construct();
     $this->load->model('Gallery_model');
     $this->load->helper(['url', 'html', 'form']);
     $this->load->library(['form_validation', 'session']);
 }
开发者ID:32x32,项目名称:spaghescript,代码行数:7,代码来源:api.php

示例6: __construct

 public function __construct()
 {
     parent::__construct();
     $this->load->model('Post');
     $this->load->model('Category');
     $this->load->model('Tag');
 }
开发者ID:csiber,项目名称:ci-blog,代码行数:7,代码来源:Posts.php

示例7:

 function __construct()
 {
     parent::__construct();
     $this->load->model(array('m_profiles', 'm_posts', 'm_projects', 'm_blogs', 'm_reviews', 'm_videos', 'm_accounts', 'm_comments', 'm_threads', 'm_banners', 'm_stats'));
     $this->load->helper(array('pretty_date'));
     $this->load->vars(array('active' => 'home'));
 }
开发者ID:ndokceplok,项目名称:Huntdrop,代码行数:7,代码来源:main.php

示例8: __construct

 /**
  * The constructor
  * @access public
  * @return void
  */
 public function __construct()
 {
     parent::__construct();
     $this->data = new stdClass();
     $this->lang->load('testimonials');
     $this->load->driver('Streams');
 }
开发者ID:jacksun101,项目名称:PyroAddons,代码行数:12,代码来源:testimonials.php

示例9:

 function __construct()
 {
     parent::__construct();
     $this->load->library('ion_auth');
     $this->load->library('postal');
     $this->load->helper('url');
 }
开发者ID:axlyody,项目名称:daijoubucms,代码行数:7,代码来源:U.php

示例10: __construct

 public function __construct()
 {
     parent::__construct();
     $this->load->model('home_model');
     $this->load->library('pagination');
     $this->load->library('facebook');
 }
开发者ID:soarmorrow,项目名称:booking-demo,代码行数:7,代码来源:home.php

示例11: __construct

 public function __construct()
 {
     parent::__construct();
     $this->load->library('facebook');
     $this->load->library('gr_auth', IMS_DB_PREFIX . 'customer');
     $this->load->model(['user_home_model', 'event_public/event_public_model', 'rating/rating_model']);
 }
开发者ID:soarmorrow,项目名称:booking-demo,代码行数:7,代码来源:user_dashboard.php

示例12: redirect

 function __construct()
 {
     parent::__construct();
     $this->load->library("go_cart");
     $this->load->helper('currency');
     $this->lang->load(array("cart"));
     $this->load->model(array("location_model"));
     /*make sure the cart isnt empty*/
     if ($this->go_cart->total_items() == 0) {
         redirect('home');
     }
     /*is the user required to be logged in?*/
     if (config_item('require_login')) {
         $this->Customer_model->is_logged_in('checkout');
     }
     if (!config_item('allow_os_purchase') && config_item('inventory_enabled')) {
         /*double check the inventory of each item before proceeding to checkout*/
         $inventory_check = $this->go_cart->check_inventory();
         if ($inventory_check) {
             /*
             OOPS we have an error. someone else has gotten the scoop on our customer and bought products out from under them!
             we need to redirect them to the view cart page and let them know that the inventory is no longer there.
             */
             $this->session->set_flashdata('error', $inventory_check);
             redirect('cart/view_cart');
         }
     }
     header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
     header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
     header("Cache-Control: no-store, no-cache, must-revalidate");
     header("Cache-Control: post-check=0, pre-check=0", false);
     header("Pragma: no-cache");
     $this->load->library('form_validation');
 }
开发者ID:nockout,项目名称:tshpro,代码行数:34,代码来源:checkout.php

示例13: __construct

 public function __construct()
 {
     parent::__construct();
     $this->config->load('files/files');
     $this->load->library('files/files');
     $this->_path = FCPATH . rtrim($this->config->item('files:path'), DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR;
 }
开发者ID:jacksun101,项目名称:PyroAddons,代码行数:7,代码来源:show.php

示例14:

 function __construct()
 {
     parent::__construct();
     $this->load->helper(array('form', 'url'));
     $this->load->library('form_validation');
     //$this->load->library('security');
 }
开发者ID:kidino,项目名称:kidinoci,代码行数:7,代码来源:Auth.php

示例15: __construct

 public function __construct()
 {
     parent::__construct();
     $this->lang->load('portfolio');
     $this->load->model('portfolio/portfolio_m');
     $this->template->append_css('module::portfolio.css')->append_js('module::jquery.quicksand.js')->append_js('module::portfolio.js');
 }
开发者ID:numerogeek,项目名称:PyroFolio,代码行数:7,代码来源:portfolio.php


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