|
@@ -80,8 +80,8 @@ function initialize_events() {
|
|
|
$cdate = $month . $day . $year;
|
|
|
|
|
|
if (isset($calendardata[$cdate])){
|
|
|
- while ( $calfoo = each($calendardata[$cdate])){
|
|
|
- $daily_events["$calfoo[key]"] = $calendardata[$cdate][$calfoo['key']];
|
|
|
+ foreach ($calendardata[$cdate] as $key => $value){
|
|
|
+ $daily_events[$key] = $calendardata[$cdate][$key];
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -96,28 +96,28 @@ function display_events() {
|
|
|
|
|
|
ksort($daily_events,SORT_STRING);
|
|
|
$eo=0;
|
|
|
- while ($calfoo = each($daily_events)){
|
|
|
+ foreach ($daily_events as $key => $value) {
|
|
|
if ($eo==0){
|
|
|
$eo=4;
|
|
|
} else {
|
|
|
$eo=0;
|
|
|
}
|
|
|
|
|
|
- $ehour = substr($calfoo['key'],0,2);
|
|
|
- $eminute = substr($calfoo['key'],2,2);
|
|
|
- if (!is_array($calfoo['value'])){
|
|
|
+ $ehour = substr($key,0,2);
|
|
|
+ $eminute = substr($key,2,2);
|
|
|
+ if (!is_array($value)){
|
|
|
echo html_tag( 'tr',
|
|
|
html_tag( 'td', $ehour . ':' . $eminute, 'left' ) .
|
|
|
html_tag( 'td', ' ', 'left' ) .
|
|
|
html_tag( 'td',
|
|
|
"<font size=\"-1\"><a href=\"event_create.php?year=$year&month=$month&day=$day&hour="
|
|
|
- .substr($calfoo['key'],0,2)."\">".
|
|
|
+ .substr($key,0,2)."\">".
|
|
|
_("ADD") . "</a></font>" ,
|
|
|
'center' ) ,
|
|
|
'', $color[$eo]);
|
|
|
|
|
|
} else {
|
|
|
- $calbar=$calfoo['value'];
|
|
|
+ $calbar=$value;
|
|
|
if ($calbar['length']!=0){
|
|
|
$elength = '-'.date_intl(_("H:i"),mktime($ehour,$eminute+$calbar['length'],0,1,1,0));
|
|
|
} else {
|
|
@@ -133,10 +133,10 @@ function display_events() {
|
|
|
html_tag( 'td',
|
|
|
"<font size=\"-1\"><nobr>\n" .
|
|
|
"<a href=\"event_edit.php?year=$year&month=$month&day=$day&hour=".
|
|
|
- substr($calfoo['key'],0,2)."&minute=".substr($calfoo['key'],2,2)."\">".
|
|
|
+ substr($key,0,2)."&minute=".substr($key,2,2)."\">".
|
|
|
_("EDIT") . "</a> | \n" .
|
|
|
"<a href=\"event_delete.php?dyear=$year&dmonth=$month&dday=$day&dhour=".
|
|
|
- substr($calfoo['key'],0,2)."&dminute=".substr($calfoo['key'],2,2).
|
|
|
+ substr($key,0,2)."&dminute=".substr($key,2,2).
|
|
|
"&year=$year&month=$month&day=$day\">" .
|
|
|
_("DEL") . '</a>' .
|
|
|
"</nobr></font>\n" ,
|