function show_event_form() { global $color, $editor_size, $year, $day, $month, $hour; echo "\n<form name=\"eventscreate\" action=\"event_create.php\" method=\"post\">\n" . " <input type=\"hidden\" name=\"year\" value=\"{$year}\" />\n" . " <input type=\"hidden\" name=\"month\" value=\"{$month}\" />\n" . " <input type=\"hidden\" name=\"day\" value=\"{$day}\" />\n" . html_tag('tr') . html_tag('td', _("Start time:"), 'right', $color[4]) . "\n" . html_tag('td', '', 'left', $color[4]) . "\n" . " <select name=\"event_hour\">\n"; select_option_hour($hour); echo " </select>\n" . " : \n" . " <select name=\"event_minute\">\n"; select_option_minute("00"); echo " </select>\n" . " </td></tr>\n" . html_tag('tr') . html_tag('td', _("Length:"), 'right', $color[4]) . "\n" . html_tag('td', '', 'left', $color[4]) . "\n" . " <select name=\"event_length\">\n"; select_option_length("0"); echo " </select>\n" . " </td></tr>\n" . html_tag('tr') . html_tag('td', _("Priority:"), 'right', $color[4]) . "\n" . html_tag('td', '', 'left', $color[4]) . "\n" . " <select name=\"event_priority\">\n"; select_option_priority("0"); echo " </select>\n" . " </td></tr>\n" . html_tag('tr') . html_tag('td', _("Title:"), 'right', $color[4]) . "\n" . html_tag('td', '', 'left', $color[4]) . "\n" . " <input type=\"text\" name=\"event_title\" value=\"\" size=\"30\" maxlength=\"50\" /><br />\n" . " </td></tr>\n" . html_tag('tr', html_tag('td', "<textarea name=\"event_text\" rows=\"5\" cols=\"{$editor_size}\"></textarea>", 'left', $color[4], 'colspan="2"')) . "\n" . html_tag('tr', html_tag('td', '<input type="submit" name="send" value="' . _("Set Event") . '" />', 'left', $color[4], 'colspan="2"')) . "\n"; echo "</form>\n"; }
/** * update event info * @return void * @access private */ function update_event_form() { global $color, $editor_size, $year, $day, $month, $hour, $minute, $calendardata; $tmparray = $calendardata["{$month}{$day}{$year}"]["{$hour}{$minute}"]; $tab = ' '; echo "\n<form name=\"eventupdate\" action=\"event_edit.php\" method=\"post\">\n" . $tab . addHidden('year', $year) . $tab . addHidden('month', $month) . $tab . addHidden('day', $day) . $tab . addHidden('hour', $hour) . $tab . addHidden('minute', $minute) . $tab . addHidden('updated', 'yes') . html_tag('tr') . html_tag('td', _("Date:"), 'right', $color[4]) . "\n" . html_tag('td', '', 'left', $color[4]) . " <select name=\"event_year\">\n"; select_option_year($year); echo " </select>\n" . " \n" . " <select name=\"event_month\">\n"; select_option_month($month); echo " </select>\n" . " \n" . " <select name=\"event_day\">\n"; select_option_day($day); echo " </select>\n" . " </td></tr>\n" . html_tag('tr') . html_tag('td', _("Time:"), 'right', $color[4]) . "\n" . html_tag('td', '', 'left', $color[4]) . " <select name=\"event_hour\">\n"; select_option_hour($hour); echo " </select>\n" . " : \n" . " <select name=\"event_minute\">\n"; select_option_minute($minute); echo " </select>\n" . " </td></tr>\n" . html_tag('tr') . html_tag('td', _("Length:"), 'right', $color[4]) . "\n" . html_tag('td', '', 'left', $color[4]) . " <select name=\"event_length\">\n"; select_option_length($tmparray['length']); echo " </select>\n" . " </td></tr>\n" . html_tag('tr') . html_tag('td', _("Priority:"), 'right', $color[4]) . "\n" . html_tag('td', '', 'left', $color[4]) . " <select name=\"event_priority\">\n"; select_option_priority($tmparray['priority']); echo " </select>\n" . " </td></tr>\n" . html_tag('tr') . html_tag('td', _("Title:"), 'right', $color[4]) . "\n" . html_tag('td', addInput('event_title', $tmparray['title'], 30, 50), 'left', $color[4]) . "\n</tr>\n" . html_tag('tr') . html_tag('td', addTextArea('event_text', $tmparray['message'], $editor_size, 5), 'left', $color[4], 'colspan="2"') . '</tr>' . html_tag('tr') . html_tag('td', addSubmit(_("Update Event"), 'send'), 'left', $color[4], 'colspan="2"') . "</tr></form>\n"; }