our $USER = $ENV{'REMOTE_USER'};
my $error;
-our $TEMPLATE = HTML::Template->new(filename => 'templates/skel.tmpl');
+our $TEMPLATE = HTML::Template->new(filename => 'templates/skel.tmpl', global_vars => 1);
for my $file ("db.pl","include.pl"){
unless (my $return = do $file){
our $XML = 0;
$XML = 1 if param('xml') and $page =~ /^(raids)$/;
+our $AJAX = 1;
+
my $type = 'text/html';
if ($XML){
$type = 'text/xml';
$ND::TEMPLATE = HTML::Template->new(filename => "templates/xml.tmpl");
$ND::BODY = HTML::Template->new(filename => "templates/${page}.xml.tmpl");
}else{
- $ND::BODY = HTML::Template->new(filename => "templates/${page}.tmpl");
+ $ND::BODY = HTML::Template->new(filename => "templates/${page}.tmpl", global_vars => 1);
+ $ND::BODY->param(PAGE => $page);
}
$PLANET = undef;
$TEMPLATE = undef;
$TICK = undef;
-%GROUPS = undef;
+undef %GROUPS;
$ND::BODY = undef;
exit;