Added cgi args parser
authorJamie Cameron <jcameron@webmin.com>
Fri, 5 Jun 2009 20:43:15 +0000 (20:43 +0000)
committerJamie Cameron <jcameron@webmin.com>
Fri, 5 Jun 2009 20:43:15 +0000 (20:43 +0000)
xinetd/cgi_args.pl [new file with mode: 0644]

diff --git a/xinetd/cgi_args.pl b/xinetd/cgi_args.pl
new file mode 100644 (file)
index 0000000..4dbc4f5
--- /dev/null
@@ -0,0 +1,12 @@
+
+do 'xinetd-lib.pl';
+
+sub cgi_args
+{
+my ($cgi) = @_;
+if ($cgi eq 'edit_serv.cgi') {
+       my @conf = grep { $_->{'name'} eq 'service' } &get_xinetd_config();
+       return @conf ? 'idx='.$conf[0]->{'index'} : 'new=1';
+       }
+return undef;
+}