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


PHP AlphaUserPointsHelper::getItemidAupProfil方法代码示例

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


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

示例1: getProfileURL

	public function getProfileURL($user, $task = '', $xhtml = true) {
		if ($user == 0)
			return false;
		$user = KunenaFactory::getUser ( $user );
		$my = JFactory::getUser ();
		if ($user === false)
			return false;
		$userid = $my->id != $user->userid ? '&userid=' . AlphaUserPointsHelper::getAnyUserReferreID ( $user->userid ) : '';
		$AUP_itemid = AlphaUserPointsHelper::getItemidAupProfil ();
		return JRoute::_ ( 'index.php?option=com_alphauserpoints&view=account' . $userid . '&Itemid=' . $AUP_itemid, $xhtml );
	}
开发者ID:BillVGN,项目名称:PortalPRP,代码行数:11,代码来源:profile.php

示例2: getProfileURL

	public function getProfileURL($user, $task = '', $xhtml = true) {
		if ($user == 0)
			return false;
		$user = KunenaFactory::getUser ( $user );
		$my = JFactory::getUser ();
		if ($user === false)
			return false;
		$userid = $my->id != $user->userid ? '&userid=' . AlphaUserPointsHelper::getAnyUserReferreID ( $user->userid ) : '';
		if (method_exists ( 'AlphaUserPointsHelper', 'getItemidAupProfil' )) {
			$AUP_itemid = AlphaUserPointsHelper::getItemidAupProfil ();
		} else {
			$db = JFactory::getDBO ();
			$query = "SELECT id FROM #__menu WHERE link='index.php?option=com_alphauserpoints&view=account' AND type='component' AND published='1'";
			$db->setQuery ( $query );
			$AUP_itemid = intval ( $db->loadResult () );
		}
		return JRoute::_ ( 'index.php?option=com_alphauserpoints&view=account' . $userid . '&Itemid=' . $AUP_itemid, $xhtml );
	}
开发者ID:rich20,项目名称:Kunena,代码行数:18,代码来源:profile.php

示例3: getAupAvatar

 public static function getAupAvatar($userid, $linktoprofil = 0, $width = '', $height = '', $class = '', $otherprofileurl = '')
 {
     if (!$userid) {
         return;
     }
     if (!defined("_AUP_AVATAR_PATH")) {
         // prevent call in administrator backend
         $juriroot = str_replace(DS . 'administrator', '', JURI::root());
         define('_AUP_AVATAR_PATH', JURI::root() . 'components/com_alphauserpoints/assets/images/avatars/');
     } else {
         $juriroot = $juriroot = str_replace(DS . 'administrator', '', JURI::root());
     }
     if (!defined("_AUP_AVATAR_LIVE_PATH")) {
         // prevent call in administrator backend
         $juribase = str_replace('/administrator', '', JURI::base());
         define('_AUP_AVATAR_LIVE_PATH', $juribase . 'components/com_alphauserpoints/assets/images/avatars/');
     } else {
         $juribase = str_replace('/administrator', '', JURI::base());
     }
     $startprofil = "";
     $endprofil = "";
     $setwidth = $width != '' ? ' width="' . $width . '"' : '';
     $setheight = $height != '' ? ' height="' . $height . '"' : '';
     $setclass = $class != '' ? ' class="' . $class . '"' : '';
     $profile = AlphaUserPointsHelper::getUserInfo('', $userid);
     $avatar = $profile->avatar != '' ? _AUP_AVATAR_LIVE_PATH . $profile->avatar : _AUP_AVATAR_PATH . 'generic_gravatar_grey.png';
     //$avatar 			= JURI::root() . "components/com_alphauserpoints/assets/phpThumb/phpThumb.php?src=".$avatar."&w=" . $width ."&h=" . $height;
     $avatar = '<img src="' . $avatar . '" border="0" alt=""' . $setwidth . $setheight . $setclass . ' />';
     $profileitemid = '';
     if ($linktoprofil) {
         $profileitemid = '&amp;Itemid=' . AlphaUserPointsHelper::getItemidAupProfil();
         $profil = $otherprofileurl ? $otherprofileurl : "index.php?option=com_alphauserpoints&amp;view=account&amp;userid=" . $profile->referreid . $profileitemid;
         $startprofil = "<a href=\"" . JRoute::_($profil) . "\">";
         $endprofil = "</a>";
         $avatar = $startprofil . $avatar . $endprofil;
     }
     return $avatar;
     // USAGE
     // $avatar = AlphaUserPointsHelper::getAupAvatar($userid, [int $linktoprofil], [int $width], [int $height], [string $class], [string $otherprofileurl]);
     // if $linktoprofil set to 1, display avatar with the link to the AUP profil of this user
     // Think to call and include this API helper.php in your script
 }
开发者ID:q0821,项目名称:esportshop,代码行数:42,代码来源:helper.php


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