Hi, I want to download multiple files from the server/web to the folder I choose before (I already know the exactly link and know parser), but I don't know how to "download a file" with Perl.

So, anyone helps me how to download file with Perl (give me detail about which function or parameter...)

thanks:)

Recommended Answers

You need to check the return value of the function:

if (is_success(getstore("http://www.example.com/", "/tmp/store/file")))...

Check

Jump to Post

All 2 Replies

I have googled and try to use getstore() function.

use LWP::Simple;
getstore($url,$file);

when I run this, no problem found but I don't know does it work? because I don't know where the file will store so I cannot check it. who can tell me that.

thanks:)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.