From 4b11ad4e325ea4ca1df0c83bfd7e16981f8fa57a Mon Sep 17 00:00:00 2001 From: Jim Hu Date: Fri, 24 Mar 2006 01:46:54 +0000 Subject: improved rss/index.php --- rss/index.php | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) (limited to 'rss') diff --git a/rss/index.php b/rss/index.php index cc32049..6132290 100644 --- a/rss/index.php +++ b/rss/index.php @@ -20,6 +20,10 @@ $current_view = "rssindex"; $display_date = "RSS Info"; $filelist = availableCalendars($username, $password, $ALL_CALENDARS_COMBINED); + +if (isset($cpath) && $cpath !=''){ + $cpath_tmp = '&cpath='.$cpath; +} foreach ($filelist as $file) { // $cal_filename is the filename of the calendar without .ics // $cal is a urlencoded version of $cal_filename @@ -30,13 +34,21 @@ foreach ($filelist as $file) { }else{ $cal_tmp = getCalendarName($file); } - $cal_displayname_tmp = str_replace("32", " ", $cal_filename_tmp); + $cal_displayname_tmp = $cal_displaynames[array_search($file,$cal_filelist)]; $cal_tmp = str_replace(" ", "+", $cal_tmp); - $rss_list .= ''.$cal_displayname_tmp.' '. $calendar_lang.'
'; - $rss_list .= ''.$default_path.'/rss/rss.php?cal='.$cal_tmp.'&cpath='.$cpath.'&rssview=day
'; - $rss_list .= ''.$default_path.'/rss/rss.php?cal='.$cal_tmp.'&cpath='.$cpath.'&rssview=week
'; - $rss_list .= ''.$default_path.'/rss/rss.php?cal='.$cal_tmp.'&cpath='.$cpath.'&rssview=month
'; - $rss_list .= ''.$default_path.'/rss/rss.php?cal='.$cal_tmp.'&cpath='.$cpath.'&rssview=year
'; + $rss_list .= '
'.$cal_displayname_tmp.' '. $lang['l_calendar'].'
'; + $rss_list .= ''; + + $rss_list .= ''; + + $rss_list .= ''; + + $rss_list .= ''; + $rss_list .='
'.$lang['l_day'].': + '.$default_path.'/rss/rss.php?cal='.$cal_tmp.$cpath_tmp.'&rssview=day
'.$lang['l_week'].': + '.$default_path.'/rss/rss.php?cal='.$cal_tmp.$cpath_tmp.'&rssview=week
'.$lang['l_month'].': + '.$default_path.'/rss/rss.php?cal='.$cal_tmp.$cpath_tmp.'&rssview=month
'.$lang['l_year'].': + '.$default_path.'/rss/rss.php?cal='.$cal_tmp.$cpath_tmp.'&rssview=year
'; $footer_check = $default_path.'/rss/rss.php?cal='.$default_cal.'&rssview='.$default_view; } -- cgit v1.2.3