diff options
author | ivan <ivan> | 2004-04-05 09:08:39 +0000 |
---|---|---|
committer | ivan <ivan> | 2004-04-05 09:08:39 +0000 |
commit | a5651d5945c790b0d3fee0cd5082269a21adc6ee (patch) | |
tree | a1d38ee8ebed3458f9df12d66f5073e106c84822 /httemplate/misc/whois.cgi | |
parent | cbbc7e215fb2f235c05abdb8c9434bdb2385ce3f (diff) |
add whois functionality internally instead of linking to geektools
Diffstat (limited to 'httemplate/misc/whois.cgi')
-rw-r--r-- | httemplate/misc/whois.cgi | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/httemplate/misc/whois.cgi b/httemplate/misc/whois.cgi new file mode 100644 index 000000000..dd7851dc2 --- /dev/null +++ b/httemplate/misc/whois.cgi @@ -0,0 +1,25 @@ +<% + my $svcnum = $cgi->param('svcnum'); + my $custnum = $cgi->param('custnum'); + my $domain = $cgi->param('domain'); + +%> +<%= header("Whois $domain", menubar( + ( $custnum + ? ( "View this customer (#$custnum)" => "${p}view/cust_main.cgi?$custnum", + ) + : () + ), + "View this domain (#$svcnum)" => "${p}view/svc_domain.cgi?$svcnum", + "Main menu" => $p, +)) %> +<% my $whois = eval { whois($domain) }; + if ( $@ ) { + ( $whois = $@ ) =~ s/ at \/.*Net\/Whois\/Raw\.pm line \d+.*$//s; + } else { + $whois =~ s/^\n+//; + } +%> +<PRE><%= $whois %></PRE> +</BODY> +</HTML> |