[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    www/areas/events
From:       Daniel Molkentin <molkentin () kde ! org>
Date:       2008-04-17 20:38:40
Message-ID: 1208464720.246977.26625.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 798254 by danimo:

more fixup


 M  +2 -2      parse_gm_feed.inc  
 M  +5 -2      rss.php  


--- trunk/www/areas/events/parse_gm_feed.inc #798253:798254
@@ -102,7 +102,7 @@
 
     $when = $item->get_item_tags('http://schemas.google.com/g/2005', 'when');
     $date= $when[0]['attribs']['']['startTime'];
-    $startTime = $when[0]['attribs']['']['startTime'];
+    $startTime = $date;
     $endTime= $when[0]['attribs']['']['endTime'];
     $unixdate = SimplePie_Misc::parse_date($date);
     $where = $item->get_item_tags('http://schemas.google.com/g/2005', 'where');
@@ -110,7 +110,7 @@
 
     // If there's actually a title here (private events don't have titles) and it's \
not cancelled...  if (strlen(trim($item->get_title()))>1 && $status != "canceled" && \
                strlen(trim($when)) > 0) {
-        $temp[] = array('date'=>$unixdate, 'where'=>$location, \
'title'=>$item->get_title(), 'description'=>$item->get_description(), \
'link'=>$item->get_link()); +        $temp[] = array('date'=>$unixdate, \
'where'=>$location, 'title'=>$item->get_title(), \
'description'=>$item->get_description(), 'link'=>$item->get_link(), \
'permalink'=>$permalink, 'startTime'=>$startTime, 'endTime'=>$endTime');  }
 
 }
--- trunk/www/areas/events/rss.php #798253:798254
@@ -1,9 +1,12 @@
 <?php
+header("Content-Type: application/rss+xml");
 echo '<?xml version="1.0" encoding="UTF-8"?>';
 // Converts the Google Atom feed into a RSS 2.0 feed
 include_once("parse_gm_feed.inc");
 
-$max_items = $_GET['max_items'];
+$max_items = 0;
+if (array_key_exists('max_items', $_GET))
+	$max_items = $_GET['max_items'];
 $curr_item = 0;
 ?>
 
@@ -25,7 +28,7 @@
 ?>
 	<item>
 		 <title><?php echo $gCalDate.": ".$item['title']; ?></title>
-		 <link><?php //echo \
$item->get_permalink();?>http://events.kde.org/upcoming.php</link> +		 \
<link>http://events.kde.org/upcoming.php</link>  <guid><?php echo \
$item['permalink'];?></guid>  <date><?php echo date("r", $item['date'] );?></date>
 		 <startTime><?php echo date("r", $item['startTime'] );?></startTime>


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic