moved not used code to trash (rss, old perm.)
[mirrors/Kyberia-bloodline.git] / trash / function.rss_generate.php
diff --git a/trash/function.rss_generate.php b/trash/function.rss_generate.php
new file mode 100644 (file)
index 0000000..811bdaa
--- /dev/null
@@ -0,0 +1,24 @@
+<?php
+function smarty_function_rss_generate($params,&$smarty)
+{
+        require_once(INCLUDE_DIR.'/feedcreator.class.php');
+print_r($params);
+
+        $rss =& new UniversalFeedCreator();
+        $rss->title = $params['data']['global']['title'];
+        $rss->description = $params['data']['global']['description'];
+        $rss->link = $params['data']['global']['link'];
+
+
+        foreach ($params['data']['items'] as $item)
+        {
+                $item =& new FeedItem();
+                $item->title = $item['title'];
+                $item->link = $item['link'];
+                $item->description = $item['description'];
+                $rss->addItem($item);
+        }
+
+        $smarty->assign('rss_generate',$rss->createFeed());
+}
+?>
\ No newline at end of file
This page took 0.094492 seconds and 4 git commands to generate.