Trunk route from The Colonnade via Treeumphant Passage to Cave Tree Chamber
WE
White Elephant Series
Wolp
Wolpertinger Way and 110 A Day level
PD
Pleasure Dome and pitches below
Sw
Swings and Roundabouts
Question Marks
END
; # starting to read in csv file, eat header line
my ($number, $grade, $area, $desc, $ref, $station, $completion);
my $incomplete="";
my $complete="";
my $templine;
my $colon;
my @stationbits;
print "Progress: *";
my $thisyear = -1;
my $qmyear;
# While loop which reads in each line of csv file
while () {
chomp;
# Split single line into all the fields
($number, $grade, $area, $desc, $ref, $station, $completion) = &parse_csv($_);
if (!$completion) { $completion = ""; }
$completion =~ s/\r//;
if (!$station) { $station = ""; }
if (!$ref) { $ref = ""; }
# hacked in by DL, as was acting weirdly due to uninitialized variables
if (($completion ne "") and ($ref ne ""))
{
print "\n?? Backlink for completed $number\n";
print "Ref is '$ref' and completion is '$completion'\n";
}
$qmyear = substr($number, 1, 4);
if($qmyear != $thisyear)
{
$complete = "$complete\n
$qmyear
\n";
$incomplete = "$incomplete\n
$qmyear
\n";
$thisyear = $qmyear;
}
# Last field of CSV file can have weird form-feeds etc. Kill them
# Construct XHTML line
if ($ref) {
$templine = "