SampleCode
SampleCode
<html>
<td>UserName<td><input name="txtUser">
<tr>
<td >Admin Password<td><input type="password"
name="txtPass">
<tr>
<td colspan="2" align="center"><input type="submit"
value="Admin Login">
</table>
</form>
</td></tr></table>
</center>
<body>
</html>
ADD CAR OWNER
<?php
$con = mysql_connect("localhost","root",'');
mysql_select_db("carpolling", $con);
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
?>
<html>
<head><link rel="stylesheet" type="text/css" href="styles.css"></link>
</head>
<body>
<table border="0" width="100%">
<tr>
<td><?php include('pagetop.php')?>
<?php include('menugeneraltop.php')?>
</td>
</tr>
</table>
<table width="100%">
<tr><td>
<?php include('menutable.php') ?>
</td><td align="center">
<h1 align="center"><font face="TAHOMA" >Add CarOwner Details</font></h1>
<td><?php
$RecNo=($row['Records']+1);
?>
<?php
$con = mysql_connect("localhost","root",'');
mysql_select_db("carpolling", $con);
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
?>
<html>
<head><link rel="stylesheet" type="text/css" href="styles.css"></link>
</head>
<body>
<table border="0" width="100%">
<tr>
<td><?php include('pagetop.php')?>
<?php include('menugeneraltop.php')?>
</td>
</tr>
</table>
<table width="100%">
<tr><td>
<?php include('menutable.php') ?>
</td>
<td align="center">
<h2 align="center"><font face="TAHOMA" color="RED ">VEHICLE
ENTRY</font></h2>
$RecNo=$row['Records']+1;
?>
<td><input name="txtVehicleId" value='<?php echo
$RecNo ?>'>
</tr>
<tr>
</tr>
<tr>
</tr>
<tr>
</tr>
<tr>
</tr>
<tr>
<td align="right">Vehicle Name
<td><input name="txtVehicleName">
</tr>
<tr>
<td align="right">Year Of Make
<td><input name="txtYear">
</tr>
<tr>
<td align="right">No. of Seats
<td><input name="txtSeats">
</tr>
<tr>
<td align="right">Owner
</td>
<td>
<select name="cboOwnerId">
<?php
$sql="SELECT OwnerId FROM
CarOwner";
$tot=mysql_query($sql,$con);
while($row = mysql_fetch_array($tot) )
{
echo "<option>" .
$row['OwnerId'] . "</option>";
}
?>
</SELECT>
</td>
</tr>
<tr>
<td align="center" colspan=2><input type="submit"
value="Save">
<input type="reset" value="Clear"></td>
</tr>
</table>
</form>
</td></tr></table>
</body>
</html>