]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blobdiff - html/cgi-bin/connscheduler.cgi
Debuginformationen aus den CGIs entfernt
[people/pmueller/ipfire-2.x.git] / html / cgi-bin / connscheduler.cgi
index 382cefe8ac52911448a443120e7d0961c63068bf..20cf2e67dad213a538e2f1679c68f193a994de62 100644 (file)
@@ -1,10 +1,12 @@
 #!/usr/bin/perl
 #
+# IPFire CGI
+# based on:
+#
 # IPCop Connection Scheduler Web-Iface
 #
 # This code is distributed under the terms of the GPL
 #
-#
 # 2006-04-xx created by weizen_42 at ipcop-forum dot de
 # 2006-06-xx added reboot and shutdown
 # 2006-08-20 added ipsecctrl
 use strict;
 
 # enable only the following on debugging purpose
-use warnings;
-use CGI::Carp 'fatalsToBrowser';
+#use warnings;
+#use CGI::Carp 'fatalsToBrowser';
 
 require '/var/ipfire/general-functions.pl';
 require "${General::swroot}/lang.pl";
 require "${General::swroot}/header.pl";
 
-require '/var/ipcop/connscheduler/lib.pl';
+require '/var/ipfire/connscheduler/lib.pl';
+
+my %color = ();
+my %mainsettings = ();
+&General::readhash("${General::swroot}/main/settings", \%mainsettings);
+&General::readhash("/srv/web/ipfire/html/themes/".$mainsettings{'THEME'}."/include/colors.txt", \%color);
 
 my $buttontext = $Lang::tr{'add'};
 my $hiddenvalue = 'add';
@@ -406,11 +413,11 @@ for my $id ( 0 .. $#CONNSCHED::config )
   }
   elsif ( $id % 2 )
   {
-    $trcolor = "<tr bgcolor='$Header::table2colour'>";
+    $trcolor = "<tr bgcolor='$color{'color20'}'>";
   }
   else 
   {
-    $trcolor = "<tr bgcolor='$Header::table1colour'>";
+    $trcolor = "<tr bgcolor='$color{'color22'}'>";
   }
 
 print <<END
@@ -442,14 +449,14 @@ $trcolor
 <td align='center'>
   <form method='post' name='frm$id' action='$ENV{'SCRIPT_NAME'}'>
   <input type='hidden' name='ACTION' value='up' />
-  <input type='image' name='$Lang::tr{'up'}' src='/images/up.gif' alt='$Lang::tr{'ConnSched up'}' title='$Lang::tr{'ConnSched up'}' />
+  <input type='image' name='$Lang::tr{'ConnSched up'}' src='/images/up.gif' alt='$Lang::tr{'ConnSched up'}' title='$Lang::tr{'ConnSched up'}' />
   <input type='hidden' name='ID' value='$id' />
   </form>
 </td>
 <td align='center'>
   <form method='post' name='frm$id' action='$ENV{'SCRIPT_NAME'}'>
   <input type='hidden' name='ACTION' value='down' />
-  <input type='image' name='$Lang::tr{'down'}' src='/images/down.gif' alt='$Lang::tr{'ConnSched down'}' title='$Lang::tr{'ConnSched down'}' />
+  <input type='image' name='$Lang::tr{'ConnSched down'}' src='/images/down.gif' alt='$Lang::tr{'ConnSched down'}' title='$Lang::tr{'ConnSched down'}' />
   <input type='hidden' name='ID' value='$id' />
   </form>
 </td>