<body style="background-color: #ffffff;background-image:url(rail.jpg);background-repeat: repeat-y">
<center>
<table>
	<tr>	
		<td><a href="http://www.wauhaha.com/karaoke/adminaccount.php"><img src=admin.gif width=140 height=140 border=0/><br/></a></td>
		<td><a href="http://www.wauhaha.com/karaoke/adminviewmem.php"><img src=member.gif width=140 height=140 border=0/><br/></a></td>
		<td><a href="http://www.wauhaha.com/karaoke/adminviewstaff.php"><img src=staff.gif width=140 height=140 border=0/><br/></a></td>
		<td><a href="http://www.wauhaha.com/karaoke/dutytime.php"><img src=duty.gif width=140 height=140 border=0/><br/></a></td>
		<td><a href="http://www.wauhaha.com/karaoke/salary.php"><img src=salary.gif width=140 height=140 border=0/><br/></a></td>
		<td><a href=adminhistory.php><img src=leave.gif width=140 height=140 border=0/><br/></a></td>
		<td><a href=adminhistory.php><img src=job.gif width=140 height=140 border=0/><br/></a></td>
		<td><a href=adminhistory.php><img src=advertisement.gif width=140 height=140 border=0/><br/></a></td>
		<td><a href="http://www.wauhaha.com/karaoke/room.php"><img src=room.gif width=140 height=140 border=0/><br/></a></td>
		
	</tr>
</table>
<h1 align=center>Admin Extend Room</h1>

</center>

<?php

$login=mysql_connect('localhost', 'wauhaha_karaoke', 'cross123','wauhaha_karaoke');
	
	mysql_selectDB("wauhaha_karaoke",$login);
		date_default_timezone_set('Asia/Brunei');
		
		
		$RoomNo = $_GET['RoomNo'];

		$result=mysql_query("SELECT * from room where RoomNo='$RoomNo'");
		$row=mysql_fetch_array($result);
		$BookID=$row['User'];
		$ET = $row['time'];
		$rt = $row['roomtype'];
		$result2 = mysql_query("select * from roomtrans where BroomID='$BookID'");
		$row2=mysql_fetch_array($result2);
		$Name = $row2['Name'];
		$IC = $row2['IC'];
		$Contact = $row2['Contact'];
		$normal = $row2['people1'];
		$student = $row2['people2'];
echo "
<center><h3><a href='http://www.wauhaha.com/karaoke/viewroom1.php?roomtype=$rt'>Back</a></h3></center>
<form method=post action=http://www.wauhaha.com/karaoke/extend1.php?RoomNo=$RoomNo >
<table align=center>
<tr>
	<td>Room No &nbsp;&nbsp;&nbsp;:</td>
	<td>$RoomNo </td>
</tr>
<tr>
	<td>Room Type :</td>
	<td>$rt <input type=hidden name=rt value=".$rt."><input type=hidden name=et value=".$ET."></td>
</tr>
<tr>
	<td>IC Name:</td>
	<td>$Name<input type=hidden name=n value=".$Name."></td>
</tr>
<tr>
	<td>IC No:</td>
	<td>$IC<input type=hidden name=ic value=".$IC."></td>
</tr>
<tr>
	<td>Contact:</td>
	<td>$Contact<input type=hidden name=c value=".$Contact."></td>
</tr>
<tr>
	<td align=center>Normal &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</td>
	<td><input type=text name=q1 size=6 value=".$normal."> Peoples</td>
</tr>
<tr>
	<td align=center>Student &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</td>
	<td><input type=text name=q2 size=6 value=".$student."> Peoples  </td>
</tr>
<tr>
	<td align=center>Hours &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</td>
	<td><select name=h ><option>3</option><option>6</option></select></td>
</tr>
<tr>	
	<td align=center colspan=2><input type=submit value=Extend><input type=reset value=Reset></td>
	
</tr>
</table>";

















?>