#!/usr/bin/perl -w

# $Id: main.pl,v 1.4 1996/01/20 08:44:51 hoagland Exp $

# main.pl, by Jim Hoagland (hoagland@cs) 1/96

# this program generates the main page for the ARPA IDS demo GUI
# may be executed as a CGI script or execed by a program
# outputs HTML to STDOUT

require 5.000;
#require Class::Eroot;

require '/pkg/www/arpa/secret/cgi-bin/gui-helper.pl';

umask 000;

#$eroot = new EROOT ( 'Name' => &get_statefile, 'Key' => 'arpa-gui' );
#
#my $state;
#if ($eroot->Continue) {
#  print "no previous state data\n";
#   $state = State->new;
#   print $state,"\n";
#   $eroot->List;
#   $eroot->Keep( "state" => $state );
#   print $state,"\n";
#   $eroot->List;
# } else {
#   $state = $eroot->Root( 'state' );
#   print $state,"\n";
# }

$state= State->new(&get_statefile);

#-------------

print "Content-type:  text/html\n\n";
&output_instantiated_file('/pkg/www/arpa/secret/gui/html-src/mom.html',*STDOUT,'<!!! Insert WS options Here !!!>',&ws_options($state),'<!!! Insert folder options Here !!!>',&folder_options($state));
#  print $state,"\n";
#  $eroot->List;
1;
