🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: es.comp.os.linux.programacion
Article #7596

Re: webmin & perl

#7596
From: Helio.es
Date: Thu, 30 Jan 2003 16:04
29 lines
1767 bytes
He cambiado el file result.cgi, ahora guarda la info en una tabla:

-------------- result.cgi -----------------------
#!/usr/bin/perl
# index.cgi
# Lovissa sample
do '../web-lib.pl';
&init_config();
&ReadParse();
&header("Lovissa Project", "", undef, 1, 1);
print "<hr>\n";
print "<form action=\"save.cgi\"><input type=hidden value=\"$in{'ip'}\"
name=ip><input type=submit></form>\n";
print "<table border width=100%>\n";
$sh = "cat /var/log/apache/access.log | " .
"grep $in{'ip'} | " .
"tr ' ' ' ' | " .
"cut -d' ' -f1,4,5,7 | " .
"mawk ' { " .
"print \"<tr><td>\" \$1 \"</td> " .
"<td>\" \$2 \" \" \$3 \"</td> " .
"<td>\" \$4 \" </td></tr>\\n\" " .
"; } '";
print `$sh`;
print "</table>\n";
print "<hr>\n";
&footer("/", $text{'index'}, "index.cgi", "cerca");
exit;
-----------------------------------------------
Technical Details
Message-ID: <b1bid2$10oe9l$1@ID-165255.news.dfncis.de>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!fu-berlin.de!uni-berlin.de!80-25-0-142.uc.nombres.ttd.ES!not-for-mail
References: <b1bfed$109ppl$1@ID-165255.news.dfncis.de>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f86c8,b4f66c5e0ff1fbd1
X-Google-Attributes: gidf86c8,public
X-Google-ArrivalTime: 2003-01-30 08:03:47 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!fu-berlin.de!uni-berlin.de!80-25-0-142.uc.nombres.ttd.ES!not-for-mail
From: "Helio.es" <nospam_heltena@hotmail.com>
Newsgroups: es.comp.os.linux.programacion
Subject: Re: webmin & perl
Date: Thu, 30 Jan 2003 17:04:02 +0100
Lines: 31
Message-ID: <b1bid2$10oe9l$1@ID-165255.news.dfncis.de>
References: <b1bfed$109ppl$1@ID-165255.news.dfncis.de>
NNTP-Posting-Host: 80-25-0-142.uc.nombres.ttd.es (80.25.0.142)
X-Trace: fu-berlin.de 1043942626 34355509 80.25.0.142 (16 [165255])
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2720.3000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000