#!/usr/bin/perl -w
#News Goat 1.0
#
#This script loads data entries into a web page. In other words, it's a weblog.
use strict;
use CGI qw(:standard);
my $header = "$ENV{'DOCUMENT_ROOT'}/header.inc";
my $middle = "$ENV{'DOCUMENT_ROOT'}/middle.inc";
my @descfile = ();
my $entriesDir = "$ENV{'DOCUMENT_ROOT'}/entries/";
my $storiesDir = "$ENV{'DOCUMENT_ROOT'}/stories/";
my @directoryList = ();
my $footer = "$ENV{'DOCUMENT_ROOT'}/footer.inc";
my $places = "$ENV{'DOCUMENT_ROOT'}/places.inc";
my $currentYear = 0;
my $currentMonth = 0;
my @currentTime = ();
my $script = "$ENV{'SCRIPT_NAME'}";
@currentTime = localtime(time);
$currentYear = 1900 + $currentTime[5];
$currentMonth = $currentTime[4] + 1;
print header();
print "\n";
print "\n";
print "
\n";
print "\n";
print "News Goat\n";
print "\n";
open (INF, $header) or die "Cannot open file.\n";
@descfile = ;
close(INF);
print @descfile;
#Left sidebar -- links.
open (PLACES, $places) or die "Can't open places file: $!";
print "
";
while ()
{
my $title = "";
my $URL = "";
($title, $URL) = split(',');
chomp($URL);
print"".$title." \n";
}
print "