Location: PHPKode > projects > Employee Scheduling System > essv1-2/editEvent.php
<?php require_once('common.php'); 
// $Id: editEvent.php,v 1.2 2005/01/14 22:22:59 atrommer Exp $
checkUser($_SESSION['USERTYPE'], 2);
if (!$_REQUEST['event']){
	// throw an error, we need an event to edit
	accessDenied("Please select an event to edit first!");
}
$oEvent = getEventDetails($_REQUEST['event']);
doHeader("Editing Event");
?>
<form name="frmAddEvent" action="editSchedDetails.php" method="post">
	<input type="hidden" name="isSubmit">
	<input type="hidden" name="area" value="<?=$oEvent->event_area_id?>">
	<input type="hidden" name="event_id" value="<?=$oEvent->event_id?>">
	<strong>Edit a new event:</strong>
	<table cellpadding="0" cellspacing="0" border="0">
	<tr>
		<td>Event Name:</td>
		<td><input type="text" name="tbName" value="<?=$oEvent->event_name?>"></td>
	</tr>
	<tr class=evenRow>
		<td>Event Date (M/D/Y):</td>
		<td>
		<? // draw the ddowns for dmy hm ?>
		<select name="ddMonth">
		<? drawMonthDD($oEvent->event_date); ?>
		</select>
		<select name="ddDay">
		<? drawDayDD($oEvent->event_date); ?>
		</select>
		<select name="ddYear">
		<? drawYearDD($oEvent->event_date); ?>
		</select>
		</td>
	</tr>
	<tr>
		<td>Start Time:</td>
		<td>
		<select name="ddStartTime">
		<? drawTimeDD(date("G:i", strtotime($oEvent->event_start))); ?>
		</select>
		</td>
	</tr>
	<tr class=evenRow><td>End Time:</td>
		<td>
			<select name="ddEndTime">
			<? drawTimeDD(date("G:i", strtotime($oEvent->event_end))); ?>
			</select>
		</td></tr>
	<tr><td colspan="2" align="center"><input type="submit" value="Next >" name="submit"></td></tr>
	</table>
</form>
<? doFooter(); ?>
Return current item: Employee Scheduling System