]> git.ipfire.org Git - ipfire-2.x.git/blame - html/cgi-bin/dial.cgi
SMP-Config angepasst.. CGIs usw. wurden im Windoof-Format gespeichert... muss noch...
[ipfire-2.x.git] / html / cgi-bin / dial.cgi
CommitLineData
ac1cfefa
MT
1#!/usr/bin/perl
2#
3# SmoothWall CGIs
4#
5# This code is distributed under the terms of the GPL
6#
7# (c) The SmoothWall Team
8#
9# $Id: dial.cgi,v 1.4.2.3 2005/02/22 22:21:55 gespinasse Exp $
10#
11
12use strict;
13
14# enable only the following on debugging purpose
15#use warnings;
16#use CGI::Carp 'fatalsToBrowser';
17
18require 'CONFIG_ROOT/general-functions.pl';
19require "${General::swroot}/lang.pl";
20require "${General::swroot}/header.pl";
21
22my %cgiparams=();
23
24$cgiparams{'ACTION'} = '';
25&Header::getcgihash(\%cgiparams);
26
27if ($cgiparams{'ACTION'} eq $Lang::tr{'dial'}) {
28 system('/etc/rc.d/rc.red','start') == 0
29 or &General::log("Dial failed: $?"); }
30elsif ($cgiparams{'ACTION'} eq $Lang::tr{'hangup'}) {
31 system('/etc/rc.d/rc.red','stop') == 0
32 or &General::log("Hangup failed: $?"); }
33sleep 1;
34
35print "Status: 302 Moved\nLocation: /cgi-bin/index.cgi\n\n";