= (CURRENT_TIMESTAMP - INTERVAL 14 DAY)"; $sql .= " ORDER BY startdate DESC"; $rows = $db->loadRows($sql); $articles = array(); foreach($rows as $rs) { $article = new Article($rs['articleid']); $articles[] = array( 'link' => $configuration['siteroot'] . '/index.php?articleid=' . $article->rec['articleid'] ,'title' => $article->rec['articlename'] ,'pubdate' => date('D, d M Y H:i:s O', strtotime($article->rec['startdate'])) ,'description' => $article->getHTML(false, false, true) ); } $rss = array( 'title' => 'Cheese of the Day' ,'link' => $configuration['siteroot'] ,'description' => $lang['txt']['rssdescription'] ,'language' => 'eng' ,'items' => $articles ); //print_r($rss); //die(); $smarty->assign("rss", $rss); $smarty->display('rss.tpl'); ?>