-
Notifications
You must be signed in to change notification settings - Fork 0
/
menu.php
25 lines (22 loc) · 960 Bytes
/
menu.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<?
include('top_page.php');
include('middle.php');
$category = $_GET['cat'];
include('config.php');
$mysqli = new mysqli($address,$dbuser,$dbpassword,$dbname);
echo ("<table style='empty-cells: hide' border=1 width=100% bgcolor=white cellpadding=5 cellspacing=11>");
$result = $mysqli->query("select * from menus WHERE id_menu=".$category."");
$data=$result->fetch_object();
echo ("<tr><td></td><td bgcolor=#00B246><center><h2>".$data->name."</h2></center></td><td></td></tr>");
echo "<tr><td><b>No.</b></td><td><b>Name of the Dish</b></td><td><b>Price</b></td></tr>";
$result = $mysqli->query("select * from dishes WHERE id_menu=".$category."");
while ( $data = $result->fetch_object() )
{
echo ("<tr>");
echo ("<td width=10%><font size=4 color=#C80006>".$data->sort_number."</font></td><td>".$data->name."</td><td width=10%>£".$data->price."</td>");
echo ("</tr>");
$max=0;
}
echo ("</table>");
include('footer.php');
?>