function process($params, $module) { $enable_cache = $params->get('cache', 1); $cachetime = $params->get('cache_time', 0); if ($enable_cache == 1) { $conf =& JFactory::getConfig(); $cache =& JFactory::getCache($module->module); $cache->setLifeTime($params->get('cache_time', $conf->getValue('config.cachetime') * 60)); $cache->setCaching(true); $cache->setCacheValidation(true); $items = $cache->get(array('modSobi2SlideshowHelper', 'getList'), array($params, $module)); } else { $items = modSobi2SlideshowHelper::getList($params, $module); } return $items; }
} if (!defined('K2SLIDESHOW')) { define('K2SLIDESHOW', 1); if (!defined('YTCJQUERY')) { define('YTCJQUERY', 1); JHTML::script('ytc.jquery-1.5.min.js', JURI::base() . '/modules/' . $module->module . '/assets/js/'); } JHTML::script('jquery.cycle.all.js', JURI::base() . '/modules/' . $module->module . '/assets/js/'); /* Add css*/ $browser = new Browser(); if ($browser->Name == 'msie' && floor($browser->Version) == 6) { JHTML::stylesheet('ie6.css', JURI::base() . '/modules/' . $module->module . '/assets/'); } else { if ($browser->Name == 'msie' && floor($browser->Version) == 7) { JHTML::stylesheet('style.css', JURI::base() . '/modules/' . $module->module . '/assets/'); JHTML::stylesheet('ie7.css', JURI::base() . '/modules/' . $module->module . '/assets/'); } else { JHTML::stylesheet('style.css', JURI::base() . '/modules/' . $module->module . '/assets/'); } } } $items = modSobi2SlideshowHelper::process($params, $module); $count_items = count($items); if ($total > $count_items) { $total = $count_items; } $width_buttom_middle = $total * 21 + 63; $path = JModuleHelper::getLayoutPath('mod_yt_sobi2slideshow', $theme); if (file_exists($path)) { require $path; }