Keyword

Problema con la extensión User Extended Fields

  • Carlos Morales
  • Carlos Morales's Avatar Topic Author
  • Offline
  • New Member
More
9 years 9 months ago - 9 years 9 months ago #136486 by Carlos Morales
Problema con la extensión User Extended Fields was created by Carlos Morales
Hola, soy nuevo programando en php. Tengo el módulo de k2 users y he visto que muestra una parte de información, pero quiero mostrar lo que me genera el User Extended Fields. El default.php me da esto, pero, cómo hago para mostrar los campos del User Extended?. Gracias.

<?php


// no direct access
defined('_JEXEC') or die;
$params = K2HelperUtilities::getParams('com_k2');
$limitstart = JRequest::getInt('limitstart');
?>

<div id="k2ModuleBox<?php echo $module->id; ?>" class="k2UsersBlock<?php if($params->get('moduleclass_sfx')) echo ' '.$params->get('moduleclass_sfx'); ?>">
<table id="tUsuarios">
<thead>
<tr>
<th>Avatar</th>
<th>Nombre</th>
<th>Descripción</th>
<th>Correo</th>
</tr>
</thead>
<tbody>
<?php foreach($users as $key=>$user):

$dispatcher = JDispatcher::getInstance();
JPluginHelper::importPlugin('k2');
$results = $dispatcher->trigger('onK2UserDisplay', array(&$user->profile, &$params, $limitstart));
echo $user->youtube;
?>
<tr class="<?php echo ($key%2) ? "odd" : "even"; if(count($users)==$key+1) echo ' lastItem'; ?>">
<td>
<?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; ?>
</td>
<td>
<?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; ?>
</td>
<td>
<?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; ?>
</td>
<td>
<?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; ?>
</td>
<td>
<?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; ?>
</td>
<div class="clr"></div>
</li>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>

Cómo puedo hacerlo?. Gracias por adelantado.
Last edit: 9 years 9 months ago by Carlos Morales.

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum