Location: PHPKode > projects > EasyFest > new/admin_viewAllBooth.php
<?php
include_once("include/db_connection.php");
	header("Expires: Thu, 17 May 2001 10:17:17 GMT");    // Date in the past
	header ("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); // always modified
	header ("Cache-Control: no-cache, must-revalidate");  // HTTP/1.1
	header ("Pragma: no-cache");                          // HTTP/1.0              
	session_start();
		if($_SESSION["adminloggedIn"] == FALSE){
		header("Location:admin_login.php");
		exit;
			include_once("config.php");
	}

	include('header.php');
	include('left1.php');?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>view all booths</title>
<meta name="keywords" content="" />
<meta name="Premium Series" content="" />
<link href="default.css" rel="stylesheet" type="text/css" media="screen" />

<script language="JavaScript" src="gen_validatorv31.js" type="text/javascript"></script>

<title>Untitled Document</title>
</head>

<body>
<div id="wrapper">
	<!-- start page -->
	<div id="page">
    	  <!-- start content -->
        <div id="prtCnt" align="center">
		<div id="content" align="center">
		  <div class="post">
	   
	    <div class="entry"><h2 class="title">&nbsp;Listing All Booths Information</h2><br>
<?php







$counter = mysql_fetch_array(mysql_query("SELECT COUNT(BoothId) FROM booths"));
//echo "$counter[0]"."<br/>";
$temp=mysql_query("SELECT BoothId FROM booths ORDER BY (BoothId) DESC ");
$i=1;
  $income=0;
while($counter[0]>0)
  {
$result6 = mysql_fetch_array($temp);?>




<?php




//echo $result6[0]."<br/>";

$counter[0]=$counter[0]-1;
$row = mysql_fetch_array(mysql_query("SELECT * FROM booths WHERE BoothId = $result6[0]"));
//print_r($result2);
//echo "$result2[0]"."$result2[1]"."$result2[2]"."$result2[3]"."$result2[4]";
$income = $income + $row['Charge'];
?>
<table width="94%" height="310" border="1" cellpadding="3" cellspacing="1" bgcolor="#FFFFFF">
<tr>
<td bgcolor="#E6E6E6"><strong>Attributes</strong></td>

<td bgcolor="#E6E6E6">Information</td>
</tr>
<tr>
<td bgcolor="#FFFFFF"><strong>SNo.</strong></td>

<td bgcolor="#FFFFFF"><?php echo $i; ?></td>
</tr>
<tr>
<td width="29%" bgcolor="#FFFFFF"><strong>Added bye</strong></td>

<td width="64%" bgcolor="#FFFFFF"><?php echo $row['UserName']; ?></td>
</tr>
<tr>
<td bgcolor="#FFFFFF"><strong>BoothType</strong></td>

<td bgcolor="#FFFFFF"><?php echo $row['BoothType']; ?></td>
</tr>
<tr>
<td bgcolor="#FFFFFF"><strong>Company</strong></td>

<td bgcolor="#FFFFFF"><?php echo $row['CompanyName']; ?></td>
</tr>
<tr>
<td bgcolor="#FFFFFF"><strong>PhoneNo</strong></td>

<td bgcolor="#FFFFFF"><?php echo $row['CompanyPhoneNo']; ?></td>
</tr>
<tr>
<td bgcolor="#FFFFFF"><strong>Price</strong></td>

<td bgcolor="#FFFFFF"><?php echo $row['Charge']; ?></td>
</tr>
<tr>
<td bgcolor="#FFFFFF"><strong>Length</strong></td>

<td bgcolor="#FFFFFF"><?php echo $row['Length']; ?></td>
</tr>
<tr>
<td bgcolor="#FFFFFF"><strong>Width</strong></td>

<td bgcolor="#FFFFFF"><?php echo $row['Width']; ?></td>
</tr>
<tr>
<td bgcolor="#FFFFFF"><strong>CheckInDate</strong></td>

<td bgcolor="#FFFFFF"><?php echo $row['CheckInDate']; ?></td>
</tr>
<tr>
<td bgcolor="#FFFFFF"><strong>CheckOutDate</strong></td>

<td bgcolor="#FFFFFF"><?php echo $row['CheckOutDate']; ?></td>
</tr>
<tr>
<td bgcolor="#FFFFFF"><strong>Action</strong></td>

<td bgcolor="#FFFFFF"><a href="admin_deleteBooth.php?BoothId=<?php echo $row['BoothId'];?>	"> Delete</a></td>
</tr>

</table>
<br>

 
<?php 
 $i++; }
  ?>
</table>
<?php
echo "TOtal income ";
echo $income;
?>

                    </p>
			</div>
		  </div>
		</div>
        </div>
        <!-- end content -->
		<!-- start sidebars -->
		<!-- end sidebars -->
	  <div style="clear: both;">&nbsp;</div>
	</div>
	<!-- end page -->
</div>
</html>
<?php
	include('footer.php');
?>
Return current item: EasyFest