#!/usr/bin/perl

# $Id: show_rr.pl,v 1.1 1996/01/21 09:49:24 hoagland Exp $

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

# this program invokes &draw_rr to return the HTML for the page
# displaying the routing rules for a host and allowing them to be applied
# Input is CGI, a field on a form.  Output is eventually HTML to STDOUT.

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


require CGI;

$input= new CGI;

foreach (@ARGV) {  # simulate field input
  $input->param(split('=',$_,2));
}

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

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

$ws= $input->param('name');
$state->{'last_ws'}= $ws;
$state->store;

&draw_rr($state,$ws);

1;
