I need to get the tag list of a K2 item and display it in a position in my template's index.php.
Pasting the code below in index.php allows me to retrieve's the K2 item's title:
$app = JFactory::getApplication();
$jinput = $app->input;
$option = $jinput->getCmd('option');
$view = $jinput->getCmd('view');
if ($option=="com_k2" && $view=="item")
{
$item_id = $jinput->getInt('id');
JTable::addIncludePath(JPATH_ADMINISTRATOR . '/components/com_k2/tables');
$item = JTable::getInstance('K2Item', 'Table', array());
$item->load($item_id);
echo "<p>" . $item->title . "</p>";
}
How can I tweak this to get the item's tag list instead?
Thank you!
I think a possible answer is here:
Custom K2 Content Module Assistance - Page 2 - Community Forum - JoomlaWorks
, but the code won't show so I'm not sure what to do.