setType(_DM_TYPE_MODULE);
$_DOCMAN->loadLanguage('modules');
require_once($_DOCMAN->getPath('classes', 'utils'));
$imgpath = $mosConfig_live_site.'/administrator/templates/'.$mainframe->getTemplate().'/images/';
$limit = $params->get('limit', 5 );
$desc_truncate = $params->get('desc_truncate', 200 );
// check if cache directory is writeable
$cacheDir = JPATH_BASE.DS.'cache'.DS;
if ( !is_writable( $cacheDir ) ) {
echo JText::_( 'Cache Directory Unwritable' );
return;
}
$options = array();
$options['rssUrl'] = $params->get('feed_url', _DM_DEFAULT_FEED_URL);
$options['cache_time'] = $params->get('cachetime', 86400);
$rss =& JFactory::getXMLparser('RSS', $options);
if ( $rss== false ) {
echo JText::_('Error: Feed not retrieved');
echo '
';
echo JText::_('This happens when no connection can be made to the server. Try updating to the latest DOCman version. Alternatively, you can disable this module in the module manager.');
return;
}
?>
| get_title()?> |
get_item_quantity();
if( !$cntItems ) {?>
|
$limit) ? $limit : $cntItems;
for( $j = 0; $j < $cntItems; $j++ ){
$item = & $rss->get_item($j);?>
get_title()?>get_description(), $desc_truncate) ) {?>
|
setType(_DM_TYPE_MODULE);
$_DOCMAN->loadLanguage('modules');
require_once($_DOCMAN->getPath('classes', 'utils'));
global $mosConfig_absolute_path, $mosConfig_live_site, $mainframe;
$imgpath = $mosConfig_live_site.'/administrator/templates/'.$mainframe->getTemplate().'/images/';
$limit = $params->get('limit', 5 );
$desc_truncate = $params->get('desc_truncate', 200 );
$cacheDir = $mosConfig_absolute_path . "/cache/";
$LitePath = $mosConfig_absolute_path . "/includes/Cache/Lite.php";
require_once($mosConfig_absolute_path . "/includes/domit/xml_domit_rss_lite.php");
$rss = &new xml_domit_rss_document_lite();
$rss->useCacheLite(true, $LitePath, $cacheDir, $params->get('cachetime', 86400) );
$rss->loadRSS($params->get('feed_url', _DM_DEFAULT_FEED_URL));
for ($i = 0; $i < $rss->getChannelCount(); $i++) {
$channel = &$rss->getChannel($i);?>
| getTitle()?> |
getItemCount();
if( !$cntItems ) {?>
|
$limit) ? $limit : $cntItems;
for( $j = 0; $j < $cntItems; $j++ ){
$item = & $channel->getItem($j);?>
getTitle()?>getDescription(), $desc_truncate) ) {?>
|