- ";
while ($row = mysql_fetch_object($q)){
echo"
- RecordID>$row->name"; if($row->Town != ''){echo", $row->Town";} echo" \n"; } } $time_stamp = time(); echo"
\r\n";
mail('jim.rolt@googlemail.com', $subject, $message, $headers);
}
$cen = mysql_query("SELECT northing, easting FROM latlong WHERE postcode = '$pc' LIMIT 1")or mailjim('cen', mysql_error());
$centre = mysql_fetch_object($cen);
$sql = " SELECT RecordID, name, Town, Postcode, TYPE, EstType
FROM EstDetails
INNER JOIN EstablishmentType ON EstablishmentType.ID = EstDetails.EstType
WHERE (northing BETWEEN $centre->northing-$range AND $centre->northing+$range) AND (easting BETWEEN $centre->easting-$range AND $centre->easting+$range)
AND EstType IN (1,2,4,5,7)
AND List = 1
ORDER BY EstType; ";
$q = mysql_query($sql)or mailjim('q', "
$sql".mysql_error());
if( mysql_num_rows($q) == 0 || $pc == ''){
header("Location:estcounties.cfm?&type=1&county=$co");
}
else{
$cn = mysql_query("SELECT CountyName, bcomregion FROM CountyDetails WHERE RecordID = ".intval($_GET['co']));
$con = mysql_fetch_object($cn);
echo <<Related links:
CountyName,$con->bcomregion);
?>
";
while ($row = mysql_fetch_object($q)){
echo"
";
include'dailyfeature.php';
?>