Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
Here is the output:#!/usr/bin/perl use LWP::Simple; use LWP::UserAgent; $ua = new LWP::UserAgent; my $req = new HTTP::Request 'POST','http://www.ncbi.nlm.nih.gov/htbin- +post/Entrez/query?uid=9254694&form=6&db=m&Dopt=r'; $req->content_type('application/x-www-form-urlencoded'); $req->content('match=www&errors=0'); my $res = $ua->request($req); print $res->as_string,"\n";
Thanks in advance!HTTP/1.1 200 OK Connection: close Date: Tue, 08 Apr 2003 02:33:07 GMT Via: 1.1 www.ncbi.nih.gov Server: Apache Content-Type: text/html Client-Date: Tue, 08 Apr 2003 02:33:28 GMT Client-Peer: 130.14.29.110:80 Client-Response-Num: 1 Client-Transfer-Encoding: chunked Title: Entrez Error X-Cache: MISS from www.ncbi.nih.gov <html> <head> <TITLE>Entrez Error</TITLE> </head> <body> <HR> <H1>Error</H1><P> This link contained an data type unknown to Entrez. </body> </html>
20030408 Edit by Corion: Added second pair of code tags
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: how to decide the URL
by Corion (Patriarch) on Apr 08, 2003 at 06:55 UTC |