• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP M_Controller类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: __construct

 /**
  * 构造函数
  * @access  public
  * @return  void
  */
 public function __construct()
 {
     parent::__construct();
     $this->load->model('mdl_member');
     $this->load->library('email');
     $this->this_view_data['_js'][] = 'jquery.form';
 }
开发者ID:Jiumiking,项目名称:qw,代码行数:12,代码来源:Member.php


示例2: __construct

 /**
  * 构造函数
  *
  * @access  public
  * @return  void
  */
 public function __construct()
 {
     parent::__construct();
     $this->load->model('Mdl_user');
     $this->load->model('Mdl_grade');
     $this->this_view_data['grade_data'] = $this->Mdl_grade->my_selects();
 }
开发者ID:Jiumiking,项目名称:Luck,代码行数:13,代码来源:Home.php


示例3: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->data_field = $this->field = array('name' => array('ismain' => 1, 'fieldname' => 'name', 'fieldtype' => 'Text', 'setting' => array('option' => array('width' => 273), 'validate' => array('required' => 1))));
     $this->data_field['displayorder'] = array('ismain' => 1, 'fieldname' => 'displayorder', 'fieldtype' => 'Text', 'setting' => array('option' => array('width' => 40, 'value' => '0')));
     $this->load->model('format_model');
 }
开发者ID:xxjuan,项目名称:php-coffee,代码行数:10,代码来源:Format.php


示例4: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->space = $this->get_cache('member', 'setting', 'space');
     define('SPACE_URL', $this->space['domain'] ? 'http://' . $this->space['domain'] . '/' : SITE_URL . 'space/');
     define('SPACE_THEME_PATH', SPACE_URL . 'statics/' . SITE_THEME . '/');
 }
开发者ID:xxjuan,项目名称:php-coffee,代码行数:10,代码来源:Home.php


示例5: __construct

 /**
  * 构造函数(网站表单)
  */
 public function __construct()
 {
     parent::__construct();
     $name = str_replace('form_', '', $this->router->class);
     // 表单参数为数字时按id读取
     if (is_numeric($name)) {
         $this->form = $this->get_cache('form-' . SITE_ID, $name);
     } else {
         $this->form = $this->get_cache('form-name-' . SITE_ID, $name);
     }
     if (!$this->form) {
         if (!IS_ADMIN) {
             exit($this->call_msg(lang('m-304')));
         } elseif (IS_AJAX) {
             exit(dr_json(0, lang('247')));
         } else {
             $this->admin_msg(lang('247'));
         }
     }
     $this->load->model('form_model');
     if (IS_ADMIN) {
         $this->field = array('inputtime' => array('name' => lang('104'), 'ismain' => 1, 'fieldtype' => 'Date', 'fieldname' => 'inputtime', 'setting' => array('option' => array('width' => 140), 'validate' => array('required' => 1, 'formattr' => ''))), 'inputip' => array('name' => lang('106'), 'ismain' => 1, 'fieldname' => 'inputip', 'fieldtype' => 'Text', 'setting' => array('option' => array('width' => 157, 'value' => $this->input->ip_address()), 'validate' => array('formattr' => ' /><input type="button" class="button" value="' . lang('107') . '" onclick="dr_dialog_ip(\'inputip\')" name="ip"'))));
         $this->uriprefix = 'admin/form_' . $this->form['table'] . '/';
     }
 }
开发者ID:Thebeautifullife,项目名称:yichunchengguan,代码行数:28,代码来源:D_Form.php


示例6: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->type = array(0 => lang('128'), 1 => lang('html-010'));
     $this->template->assign('type', $this->type);
     $this->template->assign('menu', $this->get_menu(array(lang('124') => 'admin/urlrule/index', lang('add') => 'admin/urlrule/add')));
 }
开发者ID:surgeon-xie,项目名称:jxseo,代码行数:10,代码来源:Urlrule.php


示例7: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->template->assign('menu', $this->get_menu(array(lang('190') => 'admin/mail/index', lang('206') => 'admin/mail/add_js', lang('325') => 'admin/mail/send', lang('112') => 'admin/mail/log')));
     // 缓存文件名称
     $this->cache_file = md5('sendmail' . $this->uid . $this->input->ip_address() . $this->input->user_agent());
 }
开发者ID:xxjuan,项目名称:php-coffee,代码行数:10,代码来源:Mail.php


示例8: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $use = $menu = array();
     $data = explode(',', SITE_NAVIGATOR);
     $this->type = (int) $this->input->get('type');
     foreach ($data as $i => $name) {
         if ($name) {
             $use[$i] = $i;
             $menu[$name] = 'admin/navigator/index' . (isset($_GET['type']) || $i ? '/type/' . $i : '');
             $this->menu[$i] = $name;
         }
     }
     // 设置默认选中
     if (!isset($use[$this->type])) {
         $this->type = @reset($use);
         $_SERVER['QUERY_STRING'] .= '&type=' . $this->type;
     }
     // 带分类参数时的选中
     if (isset($_GET['pid'])) {
         $_SERVER['QUERY_STRING'] = str_replace('&pid=' . $_GET['pid'], '', $_SERVER['QUERY_STRING']);
     }
     // 存在导航配置时才显示添加链接
     if ($this->menu) {
         $menu[lang('add')] = 'admin/navigator/add/type/' . $this->type;
     }
     $this->template->assign('menu', $this->get_menu($menu));
     $this->template->assign('name', $this->menu[$this->type]);
     // 导航默认字段
     $this->field = array('name' => array('ismain' => 1, 'fieldname' => 'name', 'fieldtype' => 'Text', 'setting' => array('option' => array('width' => 200))), 'title' => array('ismain' => 1, 'fieldname' => 'title', 'fieldtype' => 'Text', 'setting' => array('option' => array('width' => 300))), 'url' => array('name' => '', 'ismain' => 1, 'fieldname' => 'url', 'fieldtype' => 'Text', 'setting' => array('option' => array('width' => 400, 'value' => 'http://'))), 'thumb' => array('ismain' => 1, 'fieldname' => 'thumb', 'fieldtype' => 'File', 'setting' => array('option' => array('ext' => 'jpg,gif,png', 'size' => 10))));
     $this->load->model('page_model');
     $this->load->model('navigator_model');
 }
开发者ID:xxjuan,项目名称:php-coffee,代码行数:36,代码来源:Navigator.php


示例9: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->template->assign(array('menu' => $this->get_menu(array(lang('060') => 'admin/site/index', lang('add') => 'admin/site/add_js', lang('061') => isset($_GET['id']) && $_GET['id'] ? 'admin/site/config/id/' . (int) $_GET['id'] : 'admin/site/config'))));
     $this->load->model('site_model');
     $this->load->library('dconfig');
 }
开发者ID:surgeon-xie,项目名称:jxseo,代码行数:10,代码来源:Site.php


示例10: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->_menu = array(lang('073') => 'admin/module/index', lang('086') => 'admin/module/store');
     $this->template->assign(array('menu' => $this->get_menu($this->_menu), 'duri' => $this->duri));
     $this->load->model('module_model');
 }
开发者ID:xxjuan,项目名称:php-coffee,代码行数:10,代码来源:Module.php


示例11: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->_is_space();
     $this->thumb = array(array('ismain' => 1, 'fieldtype' => 'File', 'fieldname' => 'thumb', 'setting' => array('option' => array('size' => 10, 'ext' => 'jpg,gif,png'))));
     $this->load->model('space_category_model');
 }
开发者ID:xxjuan,项目名称:php-coffee,代码行数:10,代码来源:Category.php


示例12: Ajax

 public function Ajax()
 {
     parent::__construct();
     if ($this->config->item('ajax_security') !== $this->input->post('ajax_security')) {
         die('No Access Allowed');
     }
 }
开发者ID:jacovc86,项目名称:MaaseHoshev,代码行数:7,代码来源:ajax.php


示例13: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->template->assign('menu', $this->get_menu(array(lang('cat-00') => APP_DIR . '/admin/category/index', lang('258') => APP_DIR . '/admin/category/url', lang('add') => APP_DIR . '/admin/category/add')));
     $this->thumb = array(array('name' => lang('cat-18'), 'ismain' => 1, 'fieldtype' => 'File', 'fieldname' => 'thumb', 'setting' => array('option' => array('ext' => 'jpg,gif,png', 'size' => 10))));
     $this->load->model('category_model');
 }
开发者ID:xxjuan,项目名称:php-coffee,代码行数:10,代码来源:D_Category.php


示例14: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     if (!$this->admin) {
         $this->admin_msg('登录超时,请重新登录', 'index.php?c=login', 0);
     }
     $this->template->assign('menu', $this->get_menu(array('首页' => 'home/index', '网站搬家' => 'home/move', '网站升级' => 'home/update', '管理员密码' => 'home/password', '执行SQL语句' => 'home/sql')));
 }
开发者ID:xxjuan,项目名称:php-coffee,代码行数:11,代码来源:Home.php


示例15: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->template->assign('menu', $this->get_menu(array(lang('211') => 'admin/attachment/index', lang('212') => 'admin/attachment/unused')));
     $this->cache_file = md5('admin/attachment' . $this->uid . SITE_ID . $this->input->ip_address() . $this->input->user_agent());
     // 缓存文件名称
     $this->load->model('attachment_model');
 }
开发者ID:xxjuan,项目名称:php-coffee,代码行数:11,代码来源:Attachment.php


示例16: __construct

 public function __construct()
 {
     parent::__construct();
     $this->load->helper(array('form', 'html', 'url'));
     $this->load->library('form_validation');
     $this->load->model('client');
     array_push($this->data['scripts'], 'Clients');
 }
开发者ID:jacovc86,项目名称:MaaseHoshev,代码行数:8,代码来源:clients.php


示例17: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->template->assign('menu', $this->get_menu(array(lang('203') => 'admin/block/index', lang('add') => 'admin/block/add_js')));
     $this->link = $this->site[SITE_ID];
     $this->tablename = $this->db->dbprefix(SITE_ID . '_block');
     $this->field = array('name' => array('ismain' => 1, 'fieldname' => 'name', 'fieldtype' => 'Text', 'setting' => array('option' => array('width' => 200), 'validate' => array('required' => 1))), 'content' => array('ismain' => 1, 'fieldname' => 'content', 'fieldtype' => 'Textarea', 'setting' => array('option' => array('width' => '370', 'height' => 250), 'validate' => array('xss' => 1))));
 }
开发者ID:xxjuan,项目名称:php-coffee,代码行数:11,代码来源:Block.php


示例18: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     if (!$this->member['allowspace']) {
         $this->member_msg(lang('m-342'));
     }
     $this->load->model('space_model');
     $this->space = $this->space_model->get($this->uid);
 }
开发者ID:Thebeautifullife,项目名称:yichunchengguan,代码行数:12,代码来源:Space.php


示例19: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->module = $this->get_cache('module-' . SITE_ID . '-' . APP_DIR);
     if (!$this->module) {
         $this->admin_msg(lang('m-148'));
     }
     $this->load->model('tag_model');
 }
开发者ID:surgeon-xie,项目名称:jxseo,代码行数:12,代码来源:D_Tag.php


示例20: __construct

 /**
  * 构造函数
  */
 public function __construct()
 {
     parent::__construct();
     $this->load->library('Dfield', array(APP_DIR));
     $this->sysfield = array('author' => array('name' => lang('101'), 'ismain' => 1, 'fieldtype' => 'Text', 'fieldname' => 'author', 'setting' => array('option' => array('width' => 157, 'value' => $this->admin['username']), 'validate' => array('tips' => lang('102'), 'check' => '_check_member', 'required' => 1, 'formattr' => ' /><input type="button" class="button" value="' . lang('103') . '" onclick="dr_dialog_member(\'author\')" name="user"'))), 'inputtime' => array('name' => lang('104'), 'ismain' => 1, 'fieldtype' => 'Date', 'fieldname' => 'inputtime', 'setting' => array('option' => array('width' => 140), 'validate' => array('required' => 1, 'formattr' => ''))));
     if ($this->admin['adminid'] > 1) {
         $this->verify = $this->_get_verify();
     }
 }
开发者ID:Thebeautifullife,项目名称:yichunchengguan,代码行数:12,代码来源:D_Admin_Home.php



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP Mage类代码示例发布时间:2022-05-23
下一篇:
PHP MY_Model类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap