the display is all next to each other instead of neat rows any ideas
also If there is no entry in location it puts the entry above it any ideas again?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<html>
<head>
<?php
// report all errors
error_reporting(E_ALL);
// set database parameters
$dbhost = '**';
$dbuser = '**';
$dbpass = '**';
$dbname = '**';
$dbtabl = 'marker_info';
$dbtabl_loc = 'location';
// Connect to the database server
$dbcon = mysql_connect($dbhost, $dbuser, $dbpass) OR die('could not connect to MySQL: ' . mysql_error());
// Select the database
mysql_select_db ($dbname) OR die('could not connect to database: ' . mysql_error());
?>
<title>List of markers</title>
<meta http-equiv="content-type"
content="text/html; charset=iso-8859-1" />
<!-- link JavaScript and css elements close head -->
<script src="../page_elements/form_go_on_select.js"></script>
<link rel="stylesheet" type="text/css" href="../page_elements/qnctv_css_style_sheet.css" />
</head>
<!-- link body tag -->
<?php
include('../page_elements/body.htm'); //end
//for pretty html code
echo "\n"; //end
?>
<!--
<h1>Manage markers</h1>
<?php
$sql = "SELECT * FROM $dbtabl";
$results = mysql_query($sql) or die ('Failed to execute ' . $sql . ' due to ' . mysql_error());
?>
<table align="center">
<tr align="center">
<td> MARKER </td>
<!--
query databse and then
<td> company </td>
-->
<td> het </td>
<td> chr </td>
<td> cm </td>
<td> mbp </td>
<td> panel</td>
<td> dye </td>
<td> size_s </td>
<td> size_e </td>
<td> pos </td>
<td> pos1 </td>
<td> room </td>
</tr>
<?php
while ($marker_results = mysql_fetch_array($results))
{
// htmlspecial charaters not working??
// $d_no = htmlspecialchars($marker_results['d_no']);
$d_no = $marker_results['d_no'];
// to be found on serach
// $company = marker_results['company'];
$het = $marker_results['het'];
$chr = $marker_results['chr'];
$cm = $marker_results['cm'];
$mbp = $marker_results['mbp'];
$panel_no = $marker_results['panel_no'];
$dye = $marker_results['dye'];
$size_start = $marker_results['size_start'];
$size_end = $marker_results['size_end'];
$pos = $marker_results['pos'];
$pos1 = $marker_results['pos1'];
$loc = $marker_results['location'];
// get location info
$sql_loc = "SELECT room FROM $dbtabl_loc WHERE loc_i = '$loc'";
$results_loc = mysql_query($sql_loc) or die ('Failed to execute ' . $sql_loc . ' due to ' . mysql_error());
while ($marker_results_loc = mysql_fetch_array($results_loc))
{
$loc_room = $marker_results_loc['room'];
}
echo "<tr>".
"<td> $d_no </td>".
"<td> $het </td>".
"<td> $chr </td>".
"<td> $cm </td>".
"<td> $mbp </td>".
"<td> $panel_no </td>".
"<td> $dye </td>".
"<td> $size_start </td>".
"<td> $size_end </td>".
"<td> $pos </td>".
"<td> $pos1 </td>".
"<td><a href='full_loc.php?loc_i=$loc'> $loc_room </a></td>".
"<td><a href='edit_indiviual_marker.php?d_no=$d_no&loc_i=$loc'>Edit</a></td>".
"</tr>";
}
// to be found on search
// <td> $company </td>
// ADD ONCE DELETE PAGE IS READY
// <td><a href='deleteauthor.php?d_no=$d_no'>Delete</a></td>
?>
</table>
<br /><br />
<!-- ADD NEW MARKER -->
<!-- Return to front page-->
</body>
</html>