<html>
<head>
<title>Book Store</title>
</head>
<body>
<table border="1">
<tr>
<th>Product</th>
<th>Price Per Piece</th>
</tr>
<tr>
<td>Book</td>
<td>20</td>
</tr>
<tr>
<td>Pencil</td>
<td>10</td>
</tr>
<tr>
<td>Pen</td>
<td>5</td>
</tr>
</table>
<form method="POST"
action="fileread.php" >
<table border="1">
<tr>
<td>enter Your Name</td>
<td><input type="text"
name="cus_name"></td>
</tr>
<tr bgcolor="red">
<td
width="150">Product</td>
<td width="150">Name</td>
<td
width="70">Quantity</td>
</tr>
<tr>
<td width="150">Book</td>
<?php
$bookt=
array("computer","maths","science");
?>
<td width="150">
<select>
<option value=<?php $bookt[0];
?>>Computer </option>
<option value=<?php $bookt[1];
?>>Maths </option>
<option value=<?php $bookt[2];
?>>Science </option>
</select>
</td>
<td width="70"><input
type="text" size="3" name="book"></td>
</tr>
<tr>
<td
width="150">Pencil</td>
<?php
$pencilt=
array("black","green","blue");
?>
<td width="150">
<select>
<option value=<?php $pencilt[0];
?>>Black </option>
<option value=<?php $pencilt[1];
?>>Green </option>
<option value=<?php $pencilt[2];
?>>Blue </option>
</select>
</td>
<td width="70"><input
type="text" size="3" name="pencil"></td>
</tr>
<tr>
<td width="150">Pen</td>
<?php
$pen=
array("black","green","blue");
?>
<td width="150">
<select>
<option value=<?php $pen[0];
?>>Black </option>
<option value=<?php $pen[1];
?>>Green </option>
<option value=<?php $pen[2];
?>>Blue</option>
</select>
<td width="70"><input
type="text" size="3" name="pen"></td>
</tr>
<tr>
<td width="150">How do you Find
Anika Stationary</td>
<td width="70">
<select name="find">
<option value="a">I am a regular
Customer</option>
<option value="b">TV
Advertising</option>
<option value="c">Phone
Directory</option>
<option value="d">Word of
mouth</option>
</select>
</td>
<tr>
<td>City</td>
<td>
<select name="city">
<option
value="a">Jaipur</option>
<option
value="a">Kota</option>
<option
value="a">Bundi</option>
</select>
</option>
</tr>
<tr colspan="2">
<td align="center"><input
type="submit" value="submit order"
name="submit"></td>
</tr>
</table>
</form>
</body>
</html>
<?php
if(isset($_POST['submit']))
{
$book=$_POST['book'];
$pencil=$_POST['pencil'];
$pen=$_POST['pen'];
$find=$_POST['find'];
}
?>
No comments:
Post a Comment