ARGH!!!
Was just looking around my new site when i accessed one page and there were errors all over it. It was a page that was working and i have not changed it since making hat page and it was working fine before. Below is the code for the page, can anyone read through it and spot if something is missing and find out what has gone wrong?
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
ThanksPHP Code:<html>
<head>
<?php
include "db.php";
//getting dltypeid from previous page
if (isset($_GET['dltypeid'])) {
$dltypeid=$_GET['dltypeid'];
// do query
$result = mysql_query("SELECT atm_downloads.dlname, atm_downloads.link, atm_downloads.description, atm_downloads.dltypeid, atm_dltype.id, atm_dltype.pagedesc, atm_dltype.headingname, atm_dltype.type FROM atm_downloads, atm_dltype WHERE atm_downloads.dltypeid = '$dltypeid' AND atm_dltype.id = atm_downloads.dltypeid") or die('Error, query failed');
}
$row = mysql_fetch_array($result)
?>
<link rel="shortcut icon" href="http://www.atmania.com/atm.ico">
<title>::Alton Towers Mania:: - <?php echo $row['type']; ?></title>
<link rel=stylesheet type="text/css" href="style.css">
</head>
<body background="img/background.jpg" bottommargin="0" leftmargin="0" marginheight="0" marginwidth="0" rightmargin="0" topmargin="0">
<center><table width="765" height="100%" cellpadding="0" cellspacing="0" border="0" background="img/mainbackground.jpg"><tr valign="top"><td><table width="764" height="42" border="0" cellpadding="0" cellspacing="0" background="img/left1bg.jpg">
<tr valign="top">
<td width="113" background="img/toplogobg.jpg"><img src="img/blanklogo_topoflogo.jpg" width="248" height="97"></td>
<td width="651" background="img/toplogobg.jpg"><table width="95%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td><div align="center"><?php
include "header.php";
?></div></td>
</tr>
</table></td>
</tr>
<tr valign="top">
<td colspan="2" background="img/left1bg.jpg"><img src="img/left1_bottomoflogo2.jpg" width="169" height="42"></td>
</tr>
</table>
<table width="764" height="506" border="0" cellpadding="0" cellspacing="0">
<tr valign="top">
<td width="150" height="324"><table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><?php
include "nav.php";
?></td>
</tr>
</table>
<!-- menu below, copy and paste the menudivider.jpg code as necessary -->
<!-- the is code for a one letter space -->
<!-- end menu --></td>
<td width="9"> </td>
<td width="596"><BR>
<BR>
<p align="justify"><?php echo $row['pagedesc']; ?></p>
<!--PHP CODE TO ADD DOWNLOADS DYNAMICALLY-->
</div>
<table width="90%" border="1" align="center" cellpadding="0" cellspacing="0">
<tr>
<td style="vertical-align:middle" width="28%"><div align="center"><strong><?php echo $row['headingname']; ?></strong></div></td>
<td style="vertical-align:middle" width="50%"><div align="center"><strong>Description</strong></div></td>
<td style="vertical-align:middle" width="22%"><div align="center"><strong>Download</strong></div></td>
</tr>
<?php
//$downloadid=$row['id'];
// go through the database and while there are different downloads add them to the list dynamically
$row=mysql_data_seek($result,0);
while ($row = mysql_fetch_array($result)) {
echo '<tr><td style="vertical-align:middle"><div align="center">'. $row['dlname'] .'</div></td>';
echo '<td style="vertical-align:middle"><div align="center">'. $row['description'] .'</div></td>';
echo '<td style="vertical-align:middle"><div align="center"><a href="'. $row['link'] .'"><img src="img/downloadbutton.gif" border="0"></a></div></td></tr>';
}
?>
</table>
<!--END PHP CODE TO ADD DOWNLOADS DYNAMICALY-->
<p align="justify"> </p>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><div align="center">
<?php
include "footer.php";
?>
</div></td>
</tr>
</table>
</td>
<td width="8"> </td>
</tr>
</table>
</td></tr></table></center>
</body>
</html>
Neil






Bookmarks