Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
#!/usr/bin/perl use CGI qw/:standard/; use CGI qw/:fatalsToBrowser/; use warnings; use strict; print header, start_html("test"); my $geturl = url_param('geturl'); my $commentid; if($geturl eq "") { &get_url; } else { &get_site; &print_form; } sub get_url { print qq(<form name="geturl" name="geturl" method="get" action="wp. +pl">); print qq(URL: <input type="text" name="geturl">); print qq(<input type="submit" name="submiturl"></form>); } sub print_form { print "test 1"; } sub get_site { use LWP::Simple; my $content = get($geturl); print "test"; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Odd LWP::Simple problem, unintentional redirect
by Khen1950fx (Canon) on Aug 31, 2011 at 07:09 UTC | |
by Anonymous Monk on Aug 31, 2011 at 08:25 UTC | |
|
Re: Odd LWP::Simple problem, unintentional redirect
by duyet (Friar) on Aug 31, 2011 at 03:25 UTC | |
|
Re: Odd LWP::Simple problem, unintentional redirect
by Anonymous Monk on Aug 31, 2011 at 03:32 UTC |