Beispiel #1
0
 public function Admin_links()
 {
     parent::__construct();
     $this->user->require_group("Administrators");
     $this->load->model('users');
     $this->load->model('links');
 }
Beispiel #2
0
 function admin_install()
 {
     parent::__construct();
     if ($this->is_installed()) {
         redirect("/", 'location');
     }
 }
 public function Admin_themes()
 {
     parent::__construct();
     $this->user->require_group("Administrators");
     $this->load->model('users');
     $this->load->model('modules_db');
 }
Beispiel #4
0
 function Admin_files()
 {
     parent::__construct();
     if (!$this->user->is_member_of("Administrators")) {
         die;
     }
 }
Beispiel #5
0
 /**
  * Index Page for this controller.
  *
  * Maps to the following URL
  *         http://example.com/index.php/welcome
  *    - or -  
  *         http://example.com/index.php/welcome/index
  *    - or -
  * Since this controller is set as the default controller in 
  * config/routes.php, it's displayed at http://example.com/
  *
  * So any other public methods not prefixed with an underscore will
  * map to /index.php/welcome/<method_name>
  * @see http://codeigniter.com/user_guide/general/urls.html
  */
 public function Admin_ajax()
 {
     parent::__construct();
     $this->load->model('users');
     //$this->load->model('blocks');
     //$this->load->model('versions');
     $this->user =& $this->users->get_current_user();
 }
 /**
  * Index Page for this controller.
  *
  * Maps to the following URL
  *         http://example.com/index.php/welcome
  *    - or -
  *         http://example.com/index.php/welcome/index
  *    - or -
  * Since this controller is set as the default controller in
  * config/routes.php, it's displayed at http://example.com/
  *
  * So any other public methods not prefixed with an underscore will
  * map to /index.php/welcome/<method_name>
  * @see http://codeigniter.com/user_guide/general/urls.html
  */
 function __construct()
 {
     parent::__construct();
     $this->load->model('builderengine');
     if ($this->builderengine->get_option('user_dashboard_activ') != 'yes') {
         redirect("/", 'location');
     }
 }
Beispiel #7
0
 /**
  * Index Page for this controller.
  *
  * Maps to the following URL
  *         http://example.com/index.php/welcome
  *    - or -
  *         http://example.com/index.php/welcome/index
  *    - or -
  * Since this controller is set as the default controller in
  * config/routes.php, it's displayed at http://example.com/
  *
  * So any other public methods not prefixed with an underscore will
  * map to /index.php/welcome/<method_name>
  * @see http://codeigniter.com/user_guide/general/urls.html
  */
 function __construct()
 {
     parent::__construct();
     $this->user->is_verified();
     $this->load->model('builderengine');
     if ($this->builderengine->get_option('user_dashboard_activ') != 'yes') {
         redirect("/", 'location');
     }
     if ($this->builderengine->get_option('user_dashboard_blog') != 'yes') {
         redirect("user/main/dashboard", 'location');
     }
 }
Beispiel #8
0
 /**
  * Index Page for this controller.
  *
  * Maps to the following URL
  *         http://example.com/index.php/welcome
  *    - or -
  *         http://example.com/index.php/welcome/index
  *    - or -
  * Since this controller is set as the default controller in
  * config/routes.php, it's displayed at http://example.com/
  *
  * So any other public methods not prefixed with an underscore will
  * map to /index.php/welcome/<method_name>
  * @see http://codeigniter.com/user_guide/general/urls.html
  */
 public function Admin_main()
 {
     parent::__construct();
     if ($this->uri->segment(3) != 'login' && $this->uri->segment(3) != 'recover_password' && $this->uri->segment(3) != 'logout') {
         $this->user->require_group("Administrators");
     } else {
         if ($this->uri->segment(3) == 'login') {
             if ($this->user->is_logged_in()) {
                 redirect("/admin/main/dashboard", 'location');
             }
         }
     }
 }
Beispiel #9
0
 /**
  * Index Page for this controller.
  *
  * Maps to the following URL
  *         http://example.com/index.php/welcome
  *    - or -
  *         http://example.com/index.php/welcome/index
  *    - or -
  * Since this controller is set as the default controller in
  * config/routes.php, it's displayed at http://example.com/
  *
  * So any other public methods not prefixed with an underscore will
  * map to /index.php/welcome/<method_name>
  * @see http://codeigniter.com/user_guide/general/urls.html
  */
 function __construct()
 {
     parent::__construct();
     $this->load->model('builderengine');
     if ($this->builderengine->get_option('user_dashboard_activ') != 'yes') {
         redirect("/", 'location');
     }
     if ($this->uri->segment(1) == 'login' && $this->uri->segment(2)) {
         $module_id = $this->uri->segment(2);
         $this->load->model('module');
         $module = $this->module->get();
         foreach ($module->all as $key => $value) {
             if ($value->id == $module_id) {
                 /* first method */
                 if (file_exists(FCPATH . 'modules/' . $value->folder . '/controllers/' . $value->folder . '.php') && method_exists($value->folder, 'login') && is_callable(array($value->folder, 'login'))) {
                     redirect(base_url($value->folder . '/login'), 'location');
                 }
                 /* second method */
                 // switch ($value->folder) {
                 //     case 'page':
                 //         break;
                 //     case 'blog':
                 //         break;
                 //     case 'builderpayment':
                 //         break;
                 //     default:
                 //        redirect(base_url($value->folder.'/login'), 'location');
                 // }
             }
         }
     }
     if ($this->uri->segment(1) == 'login') {
         if ($this->user->is_logged_in()) {
             redirect("/user/main/dashboard", 'location');
         } else {
             redirect("/user/main/userLogin", 'location');
         }
     }
 }
Beispiel #10
0
 public function Admin_themes()
 {
     parent::__construct();
     $this->load->model('users');
     $this->load->model('modules_db');
 }
Beispiel #11
0
 /**
  * Index Page for this controller.
  *
  * Maps to the following URL
  * 		http://example.com/index.php/welcome
  *	- or -
  * 		http://example.com/index.php/welcome/index
  *	- or -
  * Since this controller is set as the default controller in
  * config/routes.php, it's displayed at http://example.com/
  *
  * So any other public methods not prefixed with an underscore will
  * map to /index.php/welcome/<method_name>
  * @see http://codeigniter.com/user_guide/general/urls.html
  */
 public function seo()
 {
     parent::__construct();
 }
Beispiel #12
0
 public function __construct()
 {
     parent::__construct();
     $this->user->require_group("Administrators");
 }
Beispiel #13
0
 function Admin()
 {
     parent::__construct();
     $this->show->set_default_breadcrumb(0, "Pages", "/admin/module/page/show_pages");
 }
Beispiel #14
0
 function Admin()
 {
     parent::__construct();
     $this->show->set_default_breadcrumb(0, "Blog", "/admin/module/blog/show_posts");
 }
Beispiel #15
0
 public function Admin_links()
 {
     parent::__construct();
     $this->load->model('users');
     $this->load->model('links');
 }
Beispiel #16
0
 public function module_blog()
 {
     parent::__construct();
 }
Beispiel #17
0
 public function ajax()
 {
     parent::__construct();
     $this->load->model('communication');
 }