<body style="background-color: #ffffff;background-image:url(rail.jpg);background-repeat: repeat-y">
<center>
<h1 align=center>View Leave </h1>
<?php $login=mysql_connect('localhost', 'wauhaha_karaoke', 'cross123','wauhaha_karaoke');
	
mysql_selectDB("wauhaha_karaoke",$login);
$Username= $_GET['Username']; 




?>
<center><a href='javascript:window.close();'>Close</a></center>
<h4><a href='http://www.wauhaha.com/karaoke/sleave.php?<?php ; echo "Username=$Username"; ?>'>Apply Leave</a>&nbsp;&nbsp;
<a href='http://www.wauhaha.com/karaoke/sviewleave.php?<?php  echo "Username=$Username"; ?>'>Applied Leave</a>&nbsp;&nbsp;
<a href='http://www.wauhaha.com/karaoke/vappleave.php?<?php  echo "Username=$Username"; ?>'>Approved Leave</a></h4>
<?php 


$result =mysql_query("select * from leave2 where id='$Username' ");
echo "<table border=1 align=center style ='font-family:Arial, Helvetica, sans-serif;font-size:1em' color='blue' bordercolorlight='tan' cellspacing=0 cellpadding=4>
 <tr bgcolor=lightblue >
					<th align=center>ID</th>
					<th align=center>Leave Remain</th>
					<th align=center>Year</th>
					
 </tr>";
 while($r=mysql_fetch_array($result)){
 $id1 = $r['id'];
 echo "<tr>
			<td align=center>".$r['id']."</td>
			<td align=center>".$r['l']."</td>
			<td align=center>".$r['year']."</td>
			
 </tr>";
 }
 
 
 
 
 
 
 
 
 
 
 echo "</tr>";
 
 ?>
