//page for displaying the val roll map info
session_start();
/***********************************************
* Copyright (c) 2002-4 TheGlasgowStory & HATII *
* Written by Brian Aitken, *
***********************************************/
include("error.inc");
include("staff/connect.php");
include("session.inc");
include("logon.php");
include("inc.inc");
if($urltp)
session_register("urltp");
/******************
* Image directory *
******************/
$imgdir = "images/valroll/";
$head = "Error opening image";
$back = "javascript:history.go(-1);";
$backtext = "Back to previous page";
//check that id variable has been passed
if (empty($ward))
{
dohead($head);
$message = "There is no image for the page to display.
If the problem persists e-mail
webmaster@theglasgowstory.com quoting error code TGSEU004.
";
error($head, $message, $back, $backtext);
}
//check that id between 1 and 37
if($ward<1 || $ward>37)
{
dohead($head);
$message = "There is no image for the page to display.
If the problem persists e-mail
webmaster@theglasgowstory.com quoting error code TGSEU004.
";
error($head, $message, $back, $backtext);
}
$id = $ward;
//query to get ward info
$info = mysql_query("select * from val_wards where id = '$id'");
if (!$info)
{
dohead($head);
$message = "TheGlasgowStory is experiencing technical difficulties.
If this problem persists please e-mail
webmaster@theglasgowstory.com quoting error code TGSEU005.
";
error($head, $message, $back, $backtext);
}
$info = mysql_fetch_array($info);
//if ID less than 10 add a zero
if($id<10)
$id = "0".$id;
$date = date(U);
$log = mysql_query("insert into accesslog set ip = '$userip', uname = '$user', logdate = '$date',
actiontype = 'Val Roll Map', details = 'ward $id'");
format_pre($pd, "TheGlasgowStory: Ward ".stripslashes($id), $feature, $_COOKIE);
?>