?
Solved

using Perl to Retrieve a Html File?

Posted on 2001-06-20
4
Medium Priority
?
222 Views
Last Modified: 2012-06-27
I would like to know how to write a Perl program to
retrieve a web page from an URL and display it
in Dos-Prompt(Windows) or in Cosole Mode(UNix)?

for example, display http://www.yahoo.com

thanks!
0
Comment
Question by:McCoffee
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 8

Accepted Solution

by:
shlomoy earned 240 total points
ID: 6209957
use LWP::Simple qw(getprint);
getprint($url);
0
 
LVL 5

Expert Comment

by:Sapa
ID: 6209995
It's already written. Look for GET script installed with libwww-perl,
and lwp-request in ActivePerl distribution.

- Sapa
0
 

Expert Comment

by:georgedb
ID: 6210199
There is also a PERL script that has been around I think at least since 1995, as I used it and still got it (somewhere). From memory:

It was written by a Jack Lund, based on HGET from Oscar Nierstrasz, and the script is called "url_get". I'm sure you can find it somewhere on the Internet.
0
 
LVL 8

Expert Comment

by:shlomoy
ID: 6213082
C?!
Was it that a lowsy answer? :-)

0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I've just discovered very important differences between Windows an Unix formats in Perl,at least 5.xx.. MOST IMPORTANT: Use Unix file format while saving Your script. otherwise it will have ^M s or smth likely weird in the EOL, Then DO NOT use m…
There are many situations when we need to display the data in sorted order. For example: Student details by name or by rank or by total marks etc. If you are working on data driven based projects then you will use sorting techniques very frequently.…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Six Sigma Control Plans

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question