You've already forked joomla_test
first commit
This commit is contained in:
222
modules/mod_k2_users/helper.php
Normal file
222
modules/mod_k2_users/helper.php
Normal file
@ -0,0 +1,222 @@
|
||||
<?php
|
||||
/**
|
||||
* @version $Id: helper.php 1812 2013-01-14 18:45:06Z lefteris.kavadas $
|
||||
* @package K2
|
||||
* @author JoomlaWorks http://www.joomlaworks.net
|
||||
* @copyright Copyright (c) 2006 - 2013 JoomlaWorks Ltd. All rights reserved.
|
||||
* @license GNU/GPL license: http://www.gnu.org/copyleft/gpl.html
|
||||
*/
|
||||
|
||||
// no direct access
|
||||
defined('_JEXEC') or die ;
|
||||
|
||||
require_once (JPATH_SITE.DS.'components'.DS.'com_k2'.DS.'helpers'.DS.'route.php');
|
||||
require_once (JPATH_SITE.DS.'components'.DS.'com_k2'.DS.'helpers'.DS.'utilities.php');
|
||||
|
||||
class modK2UsersHelper
|
||||
{
|
||||
|
||||
public static function getUsers(&$params)
|
||||
{
|
||||
|
||||
$mainframe = JFactory::getApplication();
|
||||
$user = JFactory::getUser();
|
||||
$aid = (int)$user->get('aid');
|
||||
$db = JFactory::getDBO();
|
||||
|
||||
$jnow = JFactory::getDate();
|
||||
$now = K2_JVERSION == '15' ? $jnow->toMySQL() : $jnow->toSql();
|
||||
|
||||
$nullDate = $db->getNullDate();
|
||||
$userObjects = array();
|
||||
|
||||
if (K2_JVERSION != '15')
|
||||
{
|
||||
$itemAccessCheck = " i.access IN(".implode(',', $user->getAuthorisedViewLevels()).") ";
|
||||
$categoryAccessCheck = " c.access IN(".implode(',', $user->getAuthorisedViewLevels()).") ";
|
||||
$languageCheck = '';
|
||||
if ($mainframe->getLanguageFilter())
|
||||
{
|
||||
$languageTag = JFactory::getLanguage()->getTag();
|
||||
$languageCheck = " AND c.language IN (".$db->Quote($languageTag).", ".$db->Quote('*').") AND i.language IN (".$db->Quote($languageTag).", ".$db->Quote('*').")";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$itemAccessCheck = " i.access <= {$aid} ";
|
||||
$categoryAccessCheck = " c.access <= {$aid} ";
|
||||
$languageCheck = '';
|
||||
}
|
||||
|
||||
if ($params->get('source') == 'specific' && $params->get('userIDs'))
|
||||
{
|
||||
$IDs = array();
|
||||
if (is_string($params->get('userIDs')))
|
||||
$IDs[] = $params->get('userIDs');
|
||||
else
|
||||
$IDs = $params->get('userIDs');
|
||||
|
||||
JArrayHelper::toInteger($IDs);
|
||||
|
||||
$query = "SELECT users.name,users.email, users.id AS UID, profiles.* FROM #__users AS users
|
||||
LEFT JOIN #__k2_users AS profiles ON users.id=profiles.userID
|
||||
WHERE users.block=0 AND users.id IN (".implode(',', $IDs).")";
|
||||
$db->setQuery($query);
|
||||
$userObjects = $db->loadObjectList();
|
||||
$newUserObjects = array();
|
||||
foreach ($IDs as $id)
|
||||
{
|
||||
foreach ($userObjects as $uO)
|
||||
{
|
||||
if ($uO->UID == $id)
|
||||
{
|
||||
$newUserObjects[] = $uO;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
$userObjects = $newUserObjects;
|
||||
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
|
||||
switch($params->get('filter',0))
|
||||
{
|
||||
|
||||
case 0 :
|
||||
$query = "SELECT users.name,users.email,users.id AS UID, profiles.*";
|
||||
|
||||
if ($params->get('ordering') == 'recent')
|
||||
$query .= ", MAX(i.created) AS counter";
|
||||
|
||||
$query .= " FROM #__users AS users
|
||||
LEFT JOIN #__k2_users AS profiles ON users.id=profiles.userID";
|
||||
|
||||
if ($params->get('ordering') == 'recent')
|
||||
{
|
||||
|
||||
$query .= " LEFT JOIN #__k2_items AS i ON users.id=i.created_by
|
||||
LEFT JOIN #__k2_categories AS c ON i.catid=c.id";
|
||||
}
|
||||
|
||||
$query .= " WHERE users.block=0 AND profiles.`group`=".(int)$params->get('K2UserGroup');
|
||||
|
||||
if ($params->get('ordering') == 'recent')
|
||||
{
|
||||
$query .= " AND
|
||||
i.published = 1 AND {$itemAccessCheck} AND i.trash = 0 AND c.published = 1 AND {$categoryAccessCheck} AND c.trash = 0
|
||||
AND ( i.publish_up = ".$db->Quote($nullDate)." OR i.publish_up <= ".$db->Quote($now)." )
|
||||
AND ( i.publish_down = ".$db->Quote($nullDate)." OR i.publish_down >= ".$db->Quote($now)." )
|
||||
AND i.created_by_alias=''";
|
||||
$query .= $languageCheck;
|
||||
}
|
||||
|
||||
if ($params->get('ordering') == 'alpha')
|
||||
$query .= " ORDER BY users.name";
|
||||
elseif ($params->get('ordering') == 'random')
|
||||
$query .= " ORDER BY RAND()";
|
||||
elseif ($params->get('ordering') == 'recent')
|
||||
$query .= " GROUP BY users.id ORDER BY counter DESC";
|
||||
|
||||
break;
|
||||
|
||||
case 1 :
|
||||
$query = "SELECT users.name,users.email,users.id AS UID, profiles.*, COUNT(i.id) AS counter FROM #__users AS users
|
||||
LEFT JOIN #__k2_users AS profiles ON users.id=profiles.userID
|
||||
LEFT JOIN #__k2_items AS i ON users.id=i.created_by
|
||||
LEFT JOIN #__k2_categories AS c ON i.catid=c.id
|
||||
WHERE users.block=0 AND
|
||||
i.published = 1 AND {$itemAccessCheck} AND i.trash = 0 AND c.published = 1 AND {$categoryAccessCheck} AND c.trash = 0
|
||||
AND ( i.publish_up = ".$db->Quote($nullDate)." OR i.publish_up <= ".$db->Quote($now)." )
|
||||
AND ( i.publish_down = ".$db->Quote($nullDate)." OR i.publish_down >= ".$db->Quote($now)." )
|
||||
AND i.created_by_alias=''
|
||||
{$languageCheck}
|
||||
GROUP BY users.id ORDER BY counter DESC";
|
||||
|
||||
break;
|
||||
|
||||
case 2 :
|
||||
$query = "SELECT users.name,users.email,users.id AS UID, profiles.*, MAX(i.hits) AS counter FROM #__users AS users
|
||||
LEFT JOIN #__k2_users AS profiles ON users.id=profiles.userID
|
||||
LEFT JOIN #__k2_items AS i ON users.id=i.created_by
|
||||
LEFT JOIN #__k2_categories AS c ON i.catid=c.id
|
||||
WHERE users.block=0 AND
|
||||
i.published = 1 AND {$itemAccessCheck} AND i.trash = 0 AND c.published = 1 AND {$categoryAccessCheck} AND c.trash = 0
|
||||
AND ( i.publish_up = ".$db->Quote($nullDate)." OR i.publish_up <= ".$db->Quote($now)." )
|
||||
AND ( i.publish_down = ".$db->Quote($nullDate)." OR i.publish_down >= ".$db->Quote($now)." )
|
||||
AND i.created_by_alias=''
|
||||
{$languageCheck}
|
||||
GROUP BY users.id ORDER BY counter DESC";
|
||||
break;
|
||||
|
||||
case 3 :
|
||||
$query = "SELECT users.name,users.email,users.id AS UID, profiles.*, COUNT(comment.id) AS counter FROM #__users AS users
|
||||
LEFT JOIN #__k2_users AS profiles ON users.id=profiles.userID
|
||||
LEFT JOIN #__k2_items AS i ON users.id=i.created_by
|
||||
LEFT JOIN #__k2_categories AS c ON i.catid=c.id
|
||||
LEFT JOIN #__k2_comments AS comment ON i.id=comment.itemID
|
||||
WHERE users.block=0 AND
|
||||
i.published = 1 AND {$itemAccessCheck} AND i.trash = 0 AND c.published = 1 AND {$categoryAccessCheck} AND c.trash = 0
|
||||
AND ( i.publish_up = ".$db->Quote($nullDate)." OR i.publish_up <= ".$db->Quote($now)." )
|
||||
AND ( i.publish_down = ".$db->Quote($nullDate)." OR i.publish_down >= ".$db->Quote($now)." )
|
||||
AND i.created_by_alias=''
|
||||
AND comment.published=1
|
||||
{$languageCheck}
|
||||
GROUP BY users.id ORDER BY counter DESC";
|
||||
break;
|
||||
}
|
||||
$db->setQuery($query, 0, $params->get('limit', 4));
|
||||
$userObjects = $db->loadObjectList();
|
||||
|
||||
}
|
||||
|
||||
if (count($userObjects))
|
||||
{
|
||||
foreach ($userObjects as $userObject)
|
||||
{
|
||||
|
||||
$userObject->avatar = K2HelperUtilities::getAvatar($userObject->UID, $userObject->email, $params->get('userImageWidth'));
|
||||
$userObject->link = JRoute::_(K2HelperRoute::getUserRoute($userObject->UID));
|
||||
$userObject->feed = JRoute::_(K2HelperRoute::getUserRoute($userObject->UID).'&format=feed');
|
||||
$userObject->url = htmlspecialchars($userObject->url, ENT_QUOTES, 'UTF-8');
|
||||
|
||||
if ($params->get('userItemCount'))
|
||||
{
|
||||
$query = "SELECT i.*, c.name as categoryname,c.id as categoryid, c.alias as categoryalias, c.params as categoryparams FROM #__k2_items as i LEFT JOIN #__k2_categories AS c ON c.id = i.catid WHERE i.published = 1
|
||||
AND {$itemAccessCheck}
|
||||
AND i.trash = 0
|
||||
AND c.published = 1
|
||||
AND {$categoryAccessCheck}
|
||||
AND c.trash = 0
|
||||
AND ( i.publish_up = ".$db->Quote($nullDate)." OR i.publish_up <= ".$db->Quote($now)." )
|
||||
AND ( i.publish_down = ".$db->Quote($nullDate)." OR i.publish_down >= ".$db->Quote($now)." )
|
||||
AND i.created_by=".(int)$userObject->UID."
|
||||
AND i.created_by_alias=''
|
||||
{$languageCheck}
|
||||
ORDER BY i.created DESC";
|
||||
|
||||
$db->setQuery($query, 0, $params->get('userItemCount'));
|
||||
$userObject->items = $db->loadObjectList();
|
||||
if (count($userObject->items))
|
||||
{
|
||||
foreach ($userObject->items as $item)
|
||||
{
|
||||
$link = K2HelperRoute::getItemRoute($item->id.':'.urlencode($item->alias), $item->catid.':'.urlencode($item->categoryalias));
|
||||
$item->link = urldecode(JRoute::_($link));
|
||||
$item->categoryLink = urldecode(JRoute::_(K2HelperRoute::getCategoryRoute($item->catid.':'.urlencode($item->categoryalias))));
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$userObject->items = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
return $userObjects;
|
||||
|
||||
}
|
||||
|
||||
}
|
48
modules/mod_k2_users/mod_k2_users.php
Normal file
48
modules/mod_k2_users/mod_k2_users.php
Normal file
@ -0,0 +1,48 @@
|
||||
<?php
|
||||
/**
|
||||
* @version $Id: mod_k2_users.php 1812 2013-01-14 18:45:06Z lefteris.kavadas $
|
||||
* @package K2
|
||||
* @author JoomlaWorks http://www.joomlaworks.net
|
||||
* @copyright Copyright (c) 2006 - 2013 JoomlaWorks Ltd. All rights reserved.
|
||||
* @license GNU/GPL license: http://www.gnu.org/copyleft/gpl.html
|
||||
*/
|
||||
|
||||
// no direct access
|
||||
defined('_JEXEC') or die ;
|
||||
|
||||
if (K2_JVERSION != '15')
|
||||
{
|
||||
$language = JFactory::getLanguage();
|
||||
$language->load('mod_k2.j16', JPATH_ADMINISTRATOR, null, true);
|
||||
}
|
||||
|
||||
require_once (dirname(__FILE__).DS.'helper.php');
|
||||
|
||||
// Params
|
||||
$moduleclass_sfx = $params->get('moduleclass_sfx', '');
|
||||
$getTemplate = $params->get('getTemplate', 'Default');
|
||||
$userName = $params->get('userName', 1);
|
||||
$userAvatar = $params->get('userAvatar', 1);
|
||||
$userAvatarWidthSelect = $params->get('userAvatarWidthSelect', 'custom');
|
||||
$userAvatarWidth = $params->get('userAvatarWidth', 50);
|
||||
$userDescription = $params->get('userDescription', 1);
|
||||
$userDescriptionWordLimit = $params->get('userDescriptionWordLimit');
|
||||
$userURL = $params->get('userURL', 1);
|
||||
$userEmail = $params->get('userEmail', 0);
|
||||
$userFeed = $params->get('userFeed', 1);
|
||||
$userItemCount = $params->get('userItemCount', 1);
|
||||
|
||||
// User avatar
|
||||
if ($userAvatarWidthSelect == 'inherit')
|
||||
{
|
||||
$componentParams = JComponentHelper::getParams('com_k2');
|
||||
$avatarWidth = $componentParams->get('userImageWidth');
|
||||
}
|
||||
else
|
||||
{
|
||||
$avatarWidth = $userAvatarWidth;
|
||||
}
|
||||
|
||||
$users = modK2UsersHelper::getUsers($params);
|
||||
|
||||
require (JModuleHelper::getLayoutPath('mod_k2_users', $getTemplate.DS.'default'));
|
84
modules/mod_k2_users/mod_k2_users.xml
Normal file
84
modules/mod_k2_users/mod_k2_users.xml
Normal file
@ -0,0 +1,84 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<extension type="module" client="site" version="2.5" method="upgrade">
|
||||
<name>K2 Users</name>
|
||||
<author>JoomlaWorks</author>
|
||||
<creationDate>July 8th, 2013</creationDate>
|
||||
<copyright>Copyright (c) 2006 - 2013 JoomlaWorks Ltd. All rights reserved.</copyright>
|
||||
<authorEmail>please-use-the-contact-form@joomlaworks.net</authorEmail>
|
||||
<authorUrl>www.joomlaworks.net</authorUrl>
|
||||
<version>2.6.7</version>
|
||||
<license>http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL</license>
|
||||
<description>K2_MOD_K2_USERS_DESCRTIPTION</description>
|
||||
<files>
|
||||
<filename module="mod_k2_users">mod_k2_users.php</filename>
|
||||
<filename>helper.php</filename>
|
||||
<folder>tmpl</folder>
|
||||
</files>
|
||||
<config>
|
||||
<fields name="params">
|
||||
<fieldset name="basic" addfieldpath="/administrator/components/com_k2/elements/">
|
||||
<field name="moduleclass_sfx" type="text" default="" label="K2_MODULE_CLASS_SUFFIX" description="K2_MODULE_CLASS_SUFFIX_DESCRIPTION"/>
|
||||
<field name="getTemplate" type="moduletemplate" modulename="mod_k2_users" default="Default" label="K2_SELECT_SUBTEMPLATE" description="This module utilizes on-the-fly MVC template overrides. What this means is that you can create a new sub-template folder for this module within your Joomla! template's /html/mod_k2_users/ folder. The module will then pickup the new sub-template auto-magically, without you editing any XML file or doing any other non-designer work!"/>
|
||||
<field name="source" type="list" default="0" label="K2_SOURCE" description="">
|
||||
<option value="filter">K2_RETRIEVE_USERS_USING_FILTERS</option>
|
||||
<option value="specific">K2_RETRIEVE_SPECIFIC_USERS</option>
|
||||
</field>
|
||||
<field name="" type="header" default="K2_RETRIEVE_USERS_USING_FILTERS" label="" description=""/>
|
||||
<field name="filter" type="list" default="1" label="K2_FETCH_USERS" description="">
|
||||
<option value="0">K2_BY_K2_USER_GROUP</option>
|
||||
<option value="1">K2_WITH_MOST_ITEMS</option>
|
||||
<option value="2">K2_WITH_MOST_POPULAR_ITEMS</option>
|
||||
<option value="3">K2_WITH_MOST_COMMENTED_ITEMS</option>
|
||||
</field>
|
||||
<field name="K2UserGroup" type="sql" default="" label="K2_SELECT_A_K2_USER_GROUP" query="SELECT id AS value, name AS K2UserGroup FROM #__k2_user_groups"/>
|
||||
<field name="ordering" type="list" default="1" label="K2_ORDERING" description="">
|
||||
<option value="alpha">K2_ALPHABETICAL</option>
|
||||
<option value="recent">K2_MOST_RECENT_ITEM</option>
|
||||
<option value="random">K2_RANDOM</option>
|
||||
</field>
|
||||
<field name="limit" type="text" default="4" size="4" label="K2_LIMIT" description=""/>
|
||||
<field name="" type="header" default="K2_RETRIEVE_SPECIFIC_USERS" label="" description=""/>
|
||||
<field name="userIDs" type="userslatest" default="" label="K2_SELECTED_USERS_SORT_WITH_DRAG_DROP" description="K2_DRAG_USERS_ONE_BY_ONE_TO_REORDER_THE_LIST_CLICK_THE_REMOVE_ICON_TO_REMOVE_A_USER_FROM_THE_LIST"/>
|
||||
<field name="" type="header" default="K2_DISPLAY_OPTIONS" label="" description=""/>
|
||||
<field name="userName" type="radio" default="1" label="K2_NAME" description="">
|
||||
<option value="0">K2_HIDE</option>
|
||||
<option value="1">K2_SHOW</option>
|
||||
</field>
|
||||
<field name="userAvatar" type="radio" default="1" label="K2_USER_AVATAR" description="">
|
||||
<option value="0">K2_HIDE</option>
|
||||
<option value="1">K2_SHOW</option>
|
||||
</field>
|
||||
<field name="userAvatarWidthSelect" type="list" default="custom" label="K2_USER_AVATAR_WIDTH" description="">
|
||||
<option value="inherit">K2_INHERIT_FROM_COMPONENT_PARAMETERS</option>
|
||||
<option value="custom">K2_USE_CUSTOM_WIDTH</option>
|
||||
</field>
|
||||
<field name="userAvatarWidth" type="text" default="50" size="4" label="K2_CUSTOM_WIDTH_FOR_USER_AVATAR_IN_PX" description=""/>
|
||||
<field name="userDescription" type="radio" default="1" label="K2_USER_DESCRIPTION" description="">
|
||||
<option value="0">K2_HIDE</option>
|
||||
<option value="1">K2_SHOW</option>
|
||||
</field>
|
||||
<field name="userDescriptionWordLimit" type="text" default="" size="4" label="K2_WORD_LIMIT_FOR_USER_DESCRIPTION" description=""/>
|
||||
<field name="userURL" type="radio" default="1" label="K2_URL" description="">
|
||||
<option value="0">K2_HIDE</option>
|
||||
<option value="1">K2_SHOW</option>
|
||||
</field>
|
||||
<field name="userEmail" type="radio" default="0" label="K2_EMAIL" description="">
|
||||
<option value="0">K2_HIDE</option>
|
||||
<option value="1">K2_SHOW</option>
|
||||
</field>
|
||||
<field name="userFeed" type="radio" default="1" label="K2_RSS_FEED_ICON" description="">
|
||||
<option value="0">K2_HIDE</option>
|
||||
<option value="1">K2_SHOW</option>
|
||||
</field>
|
||||
<field name="userItemCount" type="text" default="1" size="4" label="K2_ITEM_COUNT" description=""/>
|
||||
</fieldset>
|
||||
<fieldset name="advanced">
|
||||
<field name="cache" type="list" default="1" label="K2_CACHING" description="K2_SELECT_WHETHER_TO_CACHE_THE_CONTENT_OF_THIS_MODULE">
|
||||
<option value="1">K2_USE_GLOBAL</option>
|
||||
<option value="0">K2_NO_CACHING</option>
|
||||
</field>
|
||||
<field name="cache_time" type="text" default="900" label="K2_CACHE_TIME" description="K2_THE_TIME_IN_SECONDS_BEFORE_THE_MODULE_IS_RECACHED"/>
|
||||
</fieldset>
|
||||
</fields>
|
||||
</config>
|
||||
</extension>
|
83
modules/mod_k2_users/tmpl/Default/default.php
Normal file
83
modules/mod_k2_users/tmpl/Default/default.php
Normal file
@ -0,0 +1,83 @@
|
||||
<?php
|
||||
/**
|
||||
* @version $Id: default.php 1812 2013-01-14 18:45:06Z lefteris.kavadas $
|
||||
* @package K2
|
||||
* @author JoomlaWorks http://www.joomlaworks.net
|
||||
* @copyright Copyright (c) 2006 - 2013 JoomlaWorks Ltd. All rights reserved.
|
||||
* @license GNU/GPL license: http://www.gnu.org/copyleft/gpl.html
|
||||
*/
|
||||
|
||||
// no direct access
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
?>
|
||||
|
||||
<div id="k2ModuleBox<?php echo $module->id; ?>" class="k2UsersBlock<?php if($params->get('moduleclass_sfx')) echo ' '.$params->get('moduleclass_sfx'); ?>">
|
||||
<ul>
|
||||
<?php foreach($users as $key=>$user): ?>
|
||||
<li class="<?php echo ($key%2) ? "odd" : "even"; if(count($users)==$key+1) echo ' lastItem'; ?>">
|
||||
|
||||
<?php if($userAvatar && !empty($user->avatar)): ?>
|
||||
<a class="k2Avatar ubUserAvatar" rel="author" href="<?php echo $user->link; ?>" title="<?php echo K2HelperUtilities::cleanHtml($user->name); ?>">
|
||||
<img src="<?php echo $user->avatar; ?>" alt="<?php echo K2HelperUtilities::cleanHtml($user->name); ?>" style="width:<?php echo $avatarWidth; ?>px;height:auto;" />
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if($userName): ?>
|
||||
<a class="ubUserName" rel="author" href="<?php echo $user->link; ?>" title="<?php echo K2HelperUtilities::cleanHtml($user->name); ?>">
|
||||
<?php echo $user->name; ?>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if($userDescription && $user->description): ?>
|
||||
<div class="ubUserDescription">
|
||||
<?php if($userDescriptionWordLimit): ?>
|
||||
<?php echo K2HelperUtilities::wordLimit($user->description, $userDescriptionWordLimit) ?>
|
||||
<?php else: ?>
|
||||
<?php echo $user->description; ?>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if($userFeed || ($userURL && $user->url) || $userEmail): ?>
|
||||
<div class="ubUserAdditionalInfo">
|
||||
|
||||
<?php if($userFeed): ?>
|
||||
<!-- RSS feed icon -->
|
||||
<a class="ubUserFeedIcon" href="<?php echo $user->feed; ?>" title="<?php echo JText::_('K2_SUBSCRIBE_TO_THIS_USERS_RSS_FEED'); ?>">
|
||||
<span><?php echo JText::_('K2_SUBSCRIBE_TO_THIS_USERS_RSS_FEED'); ?></span>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if($userURL && $user->url): ?>
|
||||
<a class="ubUserURL" rel="me" href="<?php echo $user->url; ?>" title="<?php echo JText::_('K2_WEBSITE'); ?>" target="_blank">
|
||||
<span><?php echo JText::_('K2_WEBSITE'); ?></span>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if($userEmail): ?>
|
||||
<span class="ubUserEmail" title="<?php echo JText::_('K2_EMAIL'); ?>">
|
||||
<?php echo JHTML::_('Email.cloak', $user->email); ?>
|
||||
</span>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if($userItemCount && count($user->items)): ?>
|
||||
<h3><?php echo JText::_('K2_RECENT_ITEMS'); ?></h3>
|
||||
<ul class="ubUserItems">
|
||||
<?php foreach ($user->items as $item): ?>
|
||||
<li>
|
||||
<a href="<?php echo $item->link; ?>" title="<?php echo K2HelperUtilities::cleanHtml($item->title); ?>">
|
||||
<?php echo $item->title; ?>
|
||||
</a>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="clr"></div>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</div>
|
Reference in New Issue
Block a user