#!/usr/bin/perl
require "sm.pl";
require "sm_html.pl";
require "sm-lib.pl";
require "cookie-lib.pl";
require "Date.pl";
&formdata;
$uid=$FORM{'uid'};
$mbr_id=$FORM{'i'};
&chkuid;
if ($mbr_id eq ""){
if (&GetCookies($cookiename)){
&GetCompressedCookies($cookiename);
$cookie_id=$Cookies{'a'};
if ($cookie_id ne ""){
&chkmbr_cookie;
}
else{
&delete_cookie($cookiename);
}
}
}
if ($cookieset eq "N"){
&sh_header;
}
&sh_title ("$title");
&sh_body ($bg);
&tabs("EX");
&menubar;
&leftbar;
&listexhibit;
&rightbar;
&sh_mainpg4;
&sh_footer;
#************************************************************************
sub listexhibit{
print <
$ext1_m
Below you will find a list of our upcoming exhibitions (as and when dates/venues become available).
If you would like to be reminded of a particular exhibition simply press the Send me a Reminder button below the details for that exhibition and we will send you an email 7 days before.
If you would like to receive further details of a particular exhibition please send an email (with your postal address) to exhibitions\@sallymitchell.com.
HTML
$q = "Select f_exhibition_id, f_exhibition_title, f_exhibition_desc, f_exhibition_datetxt, f_exhibition_dateint, f_exhibition_day, f_exhibition_month, f_exhibition_year, f_subject_id from t_exhibition ORDER BY f_exhibition_dateint";
&dbmain ($d1, $d2, $q);
&dbmain ($d1, $d2, $q);
$numrows=$data->numrows;
$j=0;
while ($j<$numrows){
@record=$data->fetchrow;
$exhibition_id=@record[0];
$exhibition_title=@record[1];
$exhibition_desc=@record[2];
$exhibition_datetxt=@record[3];
$exhibition_dateint=@record[4];
$exhibition_day=@record[5];
$exhibition_month=@record[6];
$exhibition_year=@record[7];
$exhibit_subject_id=@record[8];
$exhibition_desc=~ s/\n/
/g;
&showexhibit;
$j++;
}
print <
HTML
}
sub showexhibit{
print <$exhibition_title
$exhibition_datetxt
$exhibition_desc
HTML
if ($exhibit_subject_id ne ""){
print <
Click here to see pictures in this exhibition
HTML
}
print <
HTML
if ($mbr_id ne ""){
print <
HTML
}
else{
print <
HTML
}
print <
HTML }