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


PHP KunenaController::display方法代码示例

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


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

示例1: display

 public function display($cachable = false, $urlparams = false)
 {
     // Redirect profile to integrated component if profile integration is turned on
     $redirect = 1;
     $active = $this->app->getMenu()->getActive();
     if (!empty($active)) {
         $params = $active->params;
         $redirect = $params->get('integration', 1);
     }
     if ($redirect && JRequest::getCmd('format', 'html') == 'html') {
         $profileIntegration = KunenaFactory::getProfile();
         $layout = JRequest::getCmd('layout', 'default');
         if ($profileIntegration instanceof KunenaProfileKunena) {
             // Continue
         } elseif ($layout == 'default') {
             $url = $this->me->getUrl(false);
         } elseif ($layout == 'list') {
             $url = $profileIntegration->getUserListURL('', false);
         }
         if (!empty($url)) {
             $this->setRedirect($url);
             return;
         }
     }
     $layout = JRequest::getCmd('layout', 'default');
     if ($layout == 'list') {
         if (KunenaFactory::getConfig()->userlist_allowed && JFactory::getUser()->guest) {
             $this->redirectBack();
         }
     }
     parent::display();
 }
开发者ID:proyectoseb,项目名称:University,代码行数:32,代码来源:user.php

示例2: display

 public function display($cachable = false, $urlparams = false)
 {
     // Redirect profile to integrated component if profile integration is turned on
     $redirect = 1;
     $active = $this->app->getMenu()->getActive();
     if (!empty($active)) {
         if (version_compare(JVERSION, '1.6', '>')) {
             // Joomla 1.6+
             $params = $active->params;
         } else {
             // Joomla 1.5
             $params = new JParameter($active->params);
         }
         $redirect = $params->get('integration', 1);
     }
     if ($redirect && JRequest::getCmd('format') == 'html') {
         $profileIntegration = KunenaFactory::getProfile();
         if ($profileIntegration instanceof KunenaProfileKunena) {
             // Continue
         } elseif (JRequest::getCmd('layout', 'default') == 'default') {
             $url = $this->me->getUrl(false);
         } elseif (JRequest::getCmd('layout') == 'list') {
             $url = $profileIntegration->getUserListURL('', false);
         }
         if (!empty($url)) {
             $this->setRedirect($url);
             return;
         }
     }
     parent::display();
 }
开发者ID:laiello,项目名称:senluonirvana,代码行数:31,代码来源:user.php

示例3: display

 public function display($cachable = false, $urlparams = false)
 {
     $db = JFactory::getDbo();
     // Enable Kunena updates if they were disabled (but only every 6 hours or logout/login).
     $now = time();
     $timestamp = $this->app->getUserState('pkg_kunena.updateCheck', 0);
     if ($timestamp < $now) {
         $query = $db->getQuery(true)->update($db->quoteName('#__update_sites'))->set($db->quoteName('enabled') . '=1')->where($db->quoteName('location') . ' LIKE ' . $db->quote('http://update.kunena.org/%'));
         $db->setQuery($query);
         $db->execute();
         $this->app->setUserState('pkg_kunena.updateCheck', $now + 60 * 60 * 6);
     }
     parent::display($cachable, $urlparams);
 }
开发者ID:kosmosby,项目名称:medicine-prof,代码行数:14,代码来源:cpanel.php

示例4: display

	public function display() {
		// Redirect profile to integrated component if profile integration is turned on
		$redirect = 1;
		$active = JFactory::getApplication ()->getMenu ()->getActive ();
		if (!empty($active)) {
			$params = new JParameter($active->params);
			$redirect = $params->get('integration');
		}
		if ($redirect) {
			$profileIntegration = KunenaFactory::getProfile();
			if (!($profileIntegration instanceof KunenaProfileKunena)) {
				$url = CKunenaLink::GetProfileURL(KunenaFactory::getUser()->userid, false);
				if ($url) {
					$this->setRedirect($url);
					return;
				}
			}
		}
		parent::display();
	}
开发者ID:rich20,项目名称:Kunena,代码行数:20,代码来源:user.php


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