1
|
#!/usr/bin/perl
|
2
|
# Run the included monshow program
|
3
|
|
4
|
require './mon-lib.pl';
|
5
|
&ui_print_header(undef, $text{'show_title'}, "");
|
6
|
|
7
|
if (!-x $config{'monshow'}) {
|
8
|
print "<p>",&text('show_ecgi', "<tt>$config{'monshow'}</tt>",
|
9
|
"../config.cgi?$module_name"),"<p>\n";
|
10
|
&ui_print_footer("", $text{'index_return'});
|
11
|
exit;
|
12
|
}
|
13
|
|
14
|
&open_execute_command(CGI, "$config{'monshow'} 2>&1", 1, 1);
|
15
|
while(<CGI>) {
|
16
|
$body .= $_;
|
17
|
}
|
18
|
close(CGI);
|
19
|
|
20
|
$body =~ s/^[\000-\177]*<body[^>]*>//i;
|
21
|
$body =~ s/<\/body>[\000-\177]*$//i;
|
22
|
print $body;
|
23
|
|
24
|
&ui_print_footer("", $text{'index_return'});
|
25
|
|