Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: 500 Error

by vishi83 (Pilgrim)
on Feb 06, 2006 at 13:08 UTC ( [id://528214]=note: print w/replies, xml ) Need Help??


in reply to 500 Error

Hi man !!
I'm not clear of wat u want to know.. First be clear with your requirement.
Learn more on LWP before proceeding with your code...

The below code will extract the source code of the url passed.....


use strict; use LWP::UserAgent; use Data::Dumper; my $url="http://10.x.x.x/login.pl"; my $ua = new LWP::UserAgent; my $request = new HTTP::Request POST => $url; $request->content_type('text/xml'); my $page = $ua->request($request); if ($page->is_success) { print $page->content; } else { print $page->error_as_HTML; }

You can change $url as per ur requirement...

I think your code is not tested... Make sure you give the correct domain name ( server ).



Thank u

A perl Script without 'strict' is like a House without Roof; Both are not Safe;

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://528214]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (2)
As of 2024-04-20 01:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found