summaryrefslogtreecommitdiffstats
path: root/templates/main.php
diff options
context:
space:
mode:
authorAlessandro Cosentino <cosenal@gmail.com>2012-05-26 15:14:37 -0400
committerAlessandro Cosentino <cosenal@gmail.com>2012-05-26 15:14:37 -0400
commit6e91029b210cea92adc3534d9d77e008ced6e99d (patch)
tree16422cd4f8d300cbf0c804ccfb8d96cb6488e2e8 /templates/main.php
parentd8a193119f442c92bd47f150d149a5d1caf44a7e (diff)
create opmlimporter class
Diffstat (limited to 'templates/main.php')
-rw-r--r--templates/main.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/templates/main.php b/templates/main.php
index fc2631412..ec5a61b35 100644
--- a/templates/main.php
+++ b/templates/main.php
@@ -4,10 +4,14 @@ $mapper = new OC_News_FeedMapper();
$feed = $mapper->fetch( 'http://algorithmsforthekitchen.com/blog/?feed=rss2' );
echo "<br>" . $feed->getTitle() . "<br>";
$mapper->insert($feed);
-$feed = $mapper->find($feed->getId());
+$feed = $mapper->findWithItems($feed->getId());
echo "<br>" . $feed->getTitle() . "<br>";
$items = $feed->getItems();
+foreach($items as $item) {
+ echo $item->getTitle();
+}
+
$feed2 = $mapper->findWithItems(45);
echo "<br>" . $feed2->getTitle() . "<br>";