No Error Messages Displayed or No Code being outputted?
Posted: Fri Aug 10, 2007 6:33 am
I've been having this wiered problem over the last few days working on a site and i am unsure why. My PHP code wont run and if there is a problem no error message is being displayed, there is just a blank page.
Any advice?
Thanks
http://www.creativebubbles.co.uk/demo6/ ... p?propid=2
Any advice?
Thanks
http://www.creativebubbles.co.uk/demo6/ ... p?propid=2
Code: Select all
<?
include('./../../scripts/database.class.php');
$propid = $_GET['propid'];
$database = new database();
$link_id = $database->database_connection();
$query_news = "select * from properties where id = '$propid'";
$result_news = mysql_query($query_news) or die(mysql_error());
$file_news = mysql_fetch_array($result_news);
$total_rows_news = mysql_num_rows($result_news);
if (!$result_news)
{
print 'There was a database error when executing';
print mysql_error();
exit;
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><!-- InstanceBegin template="/Templates/template1.dwt" codeOutsideHTMLIsLocked="false" -->
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<!-- InstanceBeginEditable name="doctitle" -->
<title>Untitled Document</title>
<link href="../style/forms.css" rel="stylesheet" type="text/css" />
<!-- InstanceEndEditable -->
<!-- InstanceBeginEditable name="head" --><!-- InstanceEndEditable -->
<link href="../style/rent.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="wrapper">
<div id="header"><h1>Welcome To rent-box.net</h1>
<h2>For Landlords and Tenants</h2>
</div>
<div id="nav">
<div id="link_home"><img src="../images/home.jpg" alt="Home" width="163" height="20" border="0" usemap="#Map" />
<map name="Map" id="Map"><area shape="rect" coords="28,4,132,16" href="../index.html" />
</map></div>
<div id="link_landlords"><img src="../images/landlords.jpg" width="163" height="20" border="0" usemap="#Map2" />
<map name="Map2" id="Map2"><area shape="rect" coords="35,4,130,18" href="../landlord.html" />
</map></div>
<div id="link_tenants"><img src="../images/tenants.jpg" alt="Tenant" width="163" height="20" border="0" usemap="#Map3" />
<map name="Map3" id="Map3"><area shape="rect" coords="41,4,135,18" href="../tenant.html" />
</map></div>
<div id="link_contact"><img src="../images/contact.jpg" alt="Contact" width="163" height="20" border="0" usemap="#Map4" />
<map name="Map4" id="Map4"><area shape="rect" coords="31,4,138,18" href="../contact.html" />
</map></div>
</div>
<!-- InstanceBeginEditable name="EditRegion3" --><div id="main">
<form action="add.php" method="post" enctype="multipart/form-data" name="myform">
<fieldset>
<legend>Address Information</legend>
<ol>
<li>
<label for="streetAddress">Street Address</label>
<input type="text" id="streetAddress" name="streetAddress" value="<? echo $file_news['address_line_one']; ?>" />
</li>
<li>
<label for="town">Town</label>
<input type="text" id="town" name="town" value="<? echo $file_news['town']; ?>" />
</li>
<li>
<label for="city">City</label>
<input type="text" id="city" name="city" value="<? echo $file_news['city']; ?>" />
</li>
<li>
<label for="postcode">Postcode</label>
<input type="text" id="postcode" name="postcode" value="<? echo $file_news['postcode']; ?>" />
</li>
</ol>
</fieldset>
<fieldset>
<legend>Description</legend>
<ol>
<li>
<label for="propertyDescription">Property Description</label>
</li>
<li>
<label for="propertyRent">Property Rent (£)</label>
<input type="text" name="propertyRent" id="propertyRent" value="<? echo $file_news['rent']; ?>" />
</li>
</ol>
</fieldset>
<!--<fieldset>
<legend>Image Upload</legend>
<ol>
<li>
<label for="mainImage">Main Image</label>
<input type="file" id="mainImage" name="mainImage">
</li>
<!--<li>
<label for="secondImage">Second Image</label>
<input type="file" id="secondImage" name="secondImage" />
</li>
<li>
<label for="thirdImage">Third Image</label>
<input type="file" id="thirdImage" name="thirdImage" />
</li>
</ol>
</fieldset>-->
<fieldset>
<input type="hidden" name="prop_id" value="<? echo $file_news['id'];?>" />
<input type="submit" value="Send" />
</fieldset>
</form>
</div>
<!-- InstanceEndEditable -->
<div id="footer"><span class="footertxt1">rent box, Iveridge Hall, Wakefield Road, Leeds, LS26 8EU Copyrights 2007</span><span class="footertxt2">Tel: 0113 234 567 Email: info@rent-box.net</span></div>
</div>
</body>
<!-- InstanceEnd --></html>