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


PHP JControllerForm::display方法代码示例

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


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

示例1: edit

 public function edit($key = null, $urlVar = null)
 {
     JRequest::setVar('view', 'feed');
     JRequest::setVar('layout', 'feed');
     JRequest::setVar('hidemainmenu', 1);
     parent::display();
 }
开发者ID:ingedgarcruz,项目名称:Ninja-RSS-Syndicator,代码行数:7,代码来源:feed.php

示例2: display

 public function display($cachable = false, $urlparams = false)
 {
     /*		// Initialise variables.
     		$cachable	= true;	// Huh? Why not just put that in the constructor?
     		$user		= JFactory::getUser();
     
     		// Set the default view name and format from the Request.
     		// Note we are using w_id to avoid collisions with the router and the return page.
     		// Frontend is a bit messier than the backend.
     		$id		= $this->input->getInt('w_id');
     		$vName	= $this->input->getCmd('view', 'categories');
     		$this->input->set('view', $vName);
     
     		if ($user->get('id') ||($_SERVER['REQUEST_METHOD'] == 'POST' && $vName = 'categories')) {
     			$cachable = false;
     		}
     
     		$safeurlparams = array(
     			'id'				=> 'INT',
     			'limit'				=> 'INT',
     			'limitstart'		=> 'INT',
     			'filter_order'		=> 'CMD',
     			'filter_order_Dir'	=> 'CMD',
     			'lang'				=> 'CMD'
     		);
     
     		// Check for edit form.
     		if ($vName == 'form' && !$this->checkEditId('com_usernotify.edit.usersubs', $id)) {
     			// Somehow the person just went to the form - we don't allow that.
     			return JError::raiseError(403, JText::sprintf('JLIB_APPLICATION_ERROR_UNHELD_ID', $id));
     		}
     */
     return parent::display($cachable, $urlparams);
 }
开发者ID:ron4mac,项目名称:joomla_com_usernotify,代码行数:34,代码来源:controller.php

示例3: edit

 function edit()
 {
     JRequest::setVar('view', 'feed');
     JRequest::setVar('layout', 'feed');
     JRequest::setVar('hidemainmenu', 1);
     parent::display();
 }
开发者ID:xenten,项目名称:swift-kanban,代码行数:7,代码来源:feed.php

示例4: display

 /**
  * Proxy for getModel.
  */
 function display()
 {
     switch (JRequest::getVar('task')) {
         case 'delete':
             $this->delete();
             break;
         case 'copyItem':
             $this->copyItem();
             break;
         case 'remove_confirmed':
             $this->remove_confirmed();
             break;
         case 'categories.delete':
             $this->delete();
             break;
         case 'categories.copyItem':
             $this->copyItem();
             break;
         case 'categories.remove_confirmed':
             $this->remove_confirmed();
             break;
         default:
             JRequest::setVar('view', 'categories');
             parent::display();
             break;
     }
 }
开发者ID:brenot,项目名称:forumdesenvolvimento,代码行数:30,代码来源:categories.php

示例5: add

 public function add()
 {
     JRequest::setVar('view', 'template');
     JRequest::setVar('layout', 'add');
     JRequest::setVar('hidemainmenu', 1);
     parent::display();
 }
开发者ID:jehanryan,项目名称:Flotech,代码行数:7,代码来源:template.php

示例6: DisplayView

 function DisplayView()
 {
     $submenu = JRequest::getVar('view');
     // Add submenu
     VideotranslationHelper::addSubmenu($submenu);
     parent::display();
 }
开发者ID:rogatnev-nikita,项目名称:cloudinterpreter,代码行数:7,代码来源:pairslanguage.php

示例7: display

 /**
  * Proxy for getModel.
  */
 function display($cachable = false, $urlparams = array())
 {
     $task = $_POST['task'];
     if ($task == 'linksform.add' or $task == 'add' or $task == 'linksform.edit' or $task == 'edit') {
         $this->setRedirect('index.php?option=com_youtubegallery&view=settings&layout=edit');
         return true;
     }
     JRequest::setVar('view', 'settings');
     JRequest::setVar('layout', 'edit');
     switch (JRequest::getVar('task')) {
         case 'apply':
             $this->save();
             break;
         case 'settings.apply':
             $this->save();
             break;
         case 'save':
             $this->save();
             break;
         case 'settings.save':
             $this->save();
             break;
         case 'cancel':
             $this->cancel();
             break;
         case 'settings.cancel':
             $this->cancel();
             break;
         default:
             parent::display();
             break;
     }
 }
开发者ID:brenot,项目名称:forumdesenvolvimento,代码行数:36,代码来源:settings.php

示例8: save

 public function save($key = null, $urlVar = null)
 {
     JSession::checkToken() or jexit(JText::_('JINVALID_TOKEN'));
     $app = JFactory::getApplication();
     $model = $this->getModel('form');
     $preconfig = $app->input->post->get('config', array(), 'array');
     $task = $this->getTask();
     $config = $model->store($preconfig);
     $id = $config['pk'];
     if ($config['validate'] == 'retry') {
         parent::display();
         return true;
     }
     if ($id) {
         if ($config['stage'] > -1) {
             $link = 'index.php?option=' . CCK_COM . '&view=form&type=' . $preconfig['type'] . '&id=' . $id . $this->_getRedirectQuery();
             if ($config['stage'] > 0) {
                 $link .= '&stage=' . $config['stage'];
             }
             $this->setRedirect(htmlspecialchars_decode($link));
             return;
         }
         if ($config['message_style']) {
             if (isset($config['message'])) {
                 $msg = $config['doTranslation'] ? JText::_('COM_CCK_' . str_replace(' ', '_', trim($config['message']))) : $config['message'];
             } else {
                 $msg = JText::_('COM_CCK_SUCCESSFULLY_SAVED');
             }
             $msgType = $config['message_style'];
         } else {
             $msg = '';
             $msgType = '';
         }
     } else {
         $msg = JText::_('JERROR_AN_ERROR_HAS_OCCURRED');
         $msgType = 'error';
     }
     switch ($task) {
         case 'apply':
             $link = 'index.php?option=' . CCK_COM . '&view=form&type=' . $preconfig['type'] . '&id=' . $id . $this->_getRedirectQuery();
             break;
         case 'save2new':
             $link = 'index.php?option=' . CCK_COM . '&view=form&type=' . $preconfig['type'] . $this->_getRedirectQuery();
             break;
         case 'save2view':
             $location = JCckDatabase::loadResult('SELECT storage_location FROM #__cck_core WHERE id = ' . (int) $id);
             $sef = 0;
             $itemId2 = 0;
             if ($location) {
                 require_once JPATH_SITE . '/plugins/cck_storage_location/' . $location . '/' . $location . '.php';
                 $link = JCck::callFunc_Array('plgCCK_Storage_Location' . $location, 'getRoute', array($config['pk'], $sef, $itemId2, array('type' => $config['type'])));
                 $link = str_replace('/administrator/', '/', $link);
                 break;
             }
         default:
             $link = $this->_getRedirectQuery(true);
             break;
     }
     $this->setRedirect(htmlspecialchars_decode($link), $msg, $msgType);
 }
开发者ID:densem-2013,项目名称:exikom,代码行数:60,代码来源:form.php

示例9: display

 function display()
 {
     switch (JRequest::getVar('task')) {
         case 'cancel':
             $this->cancel();
             break;
         default:
             JRequest::setVar('view', 'themeexport');
             parent::display();
             break;
     }
 }
开发者ID:VierlingMt,项目名称:joomla-3.x,代码行数:12,代码来源:themeexport.php

示例10: display

 /**
  * Proxy for getModel.
  */
 function display($cachable = false, $urlparams = array())
 {
     $task = $_POST['task'];
     if ($task == 'linksform.add' or $task == 'add') {
         $this->setRedirect('index.php?option=com_youtubegallery&view=linksform&layout=edit');
         return true;
     }
     if ($task == 'linksform.edit' or $task == 'edit') {
         $cid = JRequest::getVar('cid', array(), 'post', 'array');
         if (!count($cid)) {
             $this->setRedirect('index.php?option=com_youtubegallery&view=linkslist', JText::_('COM_YOUTUBEGALLERY_NO_VIDEOLISTS_SELECTED'), 'error');
             return false;
         }
         $this->setRedirect('index.php?option=com_youtubegallery&view=linksform&layout=edit&id=' . $cid[0]);
         return true;
     }
     JRequest::setVar('view', 'linksform');
     JRequest::setVar('layout', 'edit');
     switch (JRequest::getVar('task')) {
         case 'apply':
             $this->save();
             break;
         case 'linksform.apply':
             $this->save();
             break;
         case 'save':
             $this->save();
             break;
         case 'linksform.save':
             $this->save();
             break;
         case 'cancel':
             $this->cancel();
             break;
         case 'linksform.cancel':
             $this->cancel();
             break;
         default:
             parent::display();
             break;
     }
 }
开发者ID:brenot,项目名称:forumdesenvolvimento,代码行数:45,代码来源:linksform.php

示例11: display

 /**
  * Proxy for getModel.
  */
 function display()
 {
     $task = $_POST['task'];
     if ($task == 'themeform.add' or $task == 'add') {
         $this->setRedirect('index.php?option=com_youtubegallery&view=themeform&layout=edit');
         return true;
     }
     if ($task == 'themeform.edit' or $task == 'edit') {
         $cid = JRequest::getVar('cid', array(), 'post', 'array');
         if (!count($cid)) {
             $this->setRedirect('index.php?option=com_youtubegallery&view=themelist', JText::_('COM_YOUTUBEGALLERY_NO_THEME_SELECTED'), 'error');
             return false;
         }
         $this->setRedirect('index.php?option=com_youtubegallery&view=themeform&layout=edit&id=' . $cid[0]);
         return true;
     }
     JRequest::setVar('hidemainmenu', true);
     JRequest::setVar('view', 'themeform');
     JRequest::setVar('layout', 'edit');
     switch ($task) {
         case 'apply':
             $this->save();
             break;
         case 'themeform.apply':
             $this->save();
             break;
         case 'save':
             $this->save();
             break;
         case 'themeform.save':
             $this->save();
             break;
         case 'cancel':
             $this->cancel();
             break;
         case 'themeform.cancel':
             $this->cancel();
             break;
     }
     parent::display();
 }
开发者ID:VierlingMt,项目名称:joomla-3.x,代码行数:44,代码来源:themeform.php

示例12: display

 public function display($cachable = false, $urlparams = false)
 {
     parent::display($cachable, $urlparams);
 }
开发者ID:Glonum,项目名称:tz_portfolio,代码行数:4,代码来源:template.php

示例13: iframe

 public function iframe()
 {
     parent::display();
     flush();
     JFactory::getApplication()->close();
 }
开发者ID:esorone,项目名称:efcpw,代码行数:6,代码来源:logs.php

示例14: import

 function import()
 {
     JRequest::setVar('view', 'newsletter');
     $id = JRequest::getInt('id', 0);
     $type = JRequest::getString('type', 'cvs');
     if ($type == 'manual') {
         $csvtemp = JRequest::getVar('csvtemp', array());
         $path_abs_root = JPATH_ADMINISTRATOR . DIRECTORY_SEPARATOR . 'components' . DIRECTORY_SEPARATOR;
         $path_rel = 'com_jinc' . DIRECTORY_SEPARATOR . 'csvtemp.csv';
         if ($fh = fopen($path_abs_root . $path_rel, 'w')) {
             fwrite($fh, implode(',', $csvtemp));
             fclose($fh);
         }
         $csvfile = array();
         $csvfile['name'] = 'csvtemp.csv';
         $csvfile['type'] = 'application/x-csv';
         $csvfile['tmp_name'] = $path_abs_root . $path_rel;
         $csvfile['error'] = 0;
         $csvfile['size'] = 0;
     } else {
         $csvfile = JRequest::getVar('csvfile', array(), 'FILES');
     }
     $view = $this->getView('newsletter', 'html');
     if (isset($csvfile['tmp_name']) && $csvfile['tmp_name'] != '' && !is_null($csvfile['tmp_name'])) {
         $mime = $csvfile['type'];
         if (true || $mime == 'application/x-csv' || $mime == 'text/csv' || $mime == 'application/csv' || $mime == 'application/excel' || $mime == 'application/vnd.ms-excel' || $mime == 'application/vnd.msexcel') {
             $model = $this->getModel('newsletter');
             if ($result = $model->import($id, $csvfile['tmp_name'])) {
                 $view->setLayout('import');
                 $view->assignRef('result', $result);
                 if ($type == 'manual') {
                     JRequest::setVar('tmpl', 'component');
                 }
                 parent::display();
             } else {
                 $msg = JText::_('COM_JINC_ERR004');
                 $link = 'index.php?option=com_jinc&view=newsletter&layout=uploadcsv&id=' . $id;
                 $this->setRedirect($link, $msg);
             }
         } else {
             $msg = JText::_('COM_JINC_ERR014') . ' ' . $csvfile['type'];
             $link = 'index.php?option=com_jinc&view=newsletter&layout=uploadcsv&id=' . $id;
             $this->setRedirect($link, $msg);
         }
     } else {
         $msg = JText::_('COM_JINC_ERR004');
         $link = 'index.php?option=com_jinc&view=newsletter&layout=uploadcsv&id=' . $id;
         $this->setRedirect($link, $msg);
     }
 }
开发者ID:sulicz,项目名称:JINC_J30,代码行数:50,代码来源:newsletter.php

示例15: copy

 /**
  * Method to copy a newsletter
  *
  * @access	public
  *
  * @return void
  */
 public function copy()
 {
     // Check for request forgeries
     if (!JSession::checkToken()) {
         jexit(JText::_('JINVALID_TOKEN'));
     }
     $app = JFactory::getApplication();
     // Access check.
     if (!self::allowAdd()) {
         $app->enqueueMessage(JText::_('COM_BWPOSTMAN_NL_COPY_CREATE_RIGHTS_MISSING'), 'error');
         return false;
     }
     $model = $this->getModel('newsletter');
     // Get the newsletter IDs to copy
     $cid = $this->input->get('cid', array(), 'array');
     $res = $model->copy($cid);
     if ($res === true) {
         $dispatcher = JEventDispatcher::getInstance();
         JPluginHelper::importPlugin('bwpostman');
         $dispatcher->trigger('onBwPostmanAfterNewsletterCopy', array());
     }
     parent::display();
 }
开发者ID:RomanaBW,项目名称:BwPostman,代码行数:30,代码来源:newsletter.php


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