hello to everybody.
I need to have in the frontpage of my template a variable with the ID of the category regardless of the type of display.
I tried this, but I have not had the desired results
thanks
M
I need to have in the frontpage of my template a variable with the ID of the category regardless of the type of display.
I tried this, but I have not had the desired results
$K2Itemid = JRequest::getInt('id');
if($K2Itemid){
$db = JFactory::getDBO();
$db->setQuery("SELECT catid FROM #__k2_items WHERE id = ".$K2Itemid );
$K2Catid = $db->loadResult();
}thanks
M