Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re^5: connecting to ftp sites and download certain files based on file extensions

by ptum (Priest)
on May 01, 2007 at 14:09 UTC ( #612994=note: print w/replies, xml ) Need Help??


in reply to Re^4: connecting to ftp sites and download certain files based on file extensions
in thread connecting to ftp sites and download certain files based on file extensions

OK, so, I think we're looking to see you make some kind of effort, here. What have you done so far? Where is your snippet of relevant and tested code (formatted, of course, in <code> tags)?

If you look at Net::FTP, you'll see a Synopsis section that shows how to build an FTP connection. Notice how the return value from each operation (new, login, etc.) is tested -- and if it is false, the 'die' instruction is executed with an appropriate error message. This is what I meant by testing to ensure that your $ftp object is really what you think it is. It is pointless to execute the 'cwd' method unless you actually have a working Net::FTP object with which to work. Based on the error message you reported when trying odha57's code above, you aren't getting past the initial new() or login() steps.

  • Comment on Re^5: connecting to ftp sites and download certain files based on file extensions

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://612994]
help
Chatterbox?
LanX where is the camera?
Tux => $HOME
[Eily]: you wrote boos instead of boss, and jedikaiti read that as boobs :)
[LanX]: Win claims only 8 MB left on C: how do I find out where the problem happens?
[Eily]: by Tux. And going home sounds like a good idea
[Eily]: LanX pretty much everywhere except in 8MB ?
[Eily]: s/by/bye/ someone hacked my keyboard I'm sure
[LanX]: good point! :)
[Eily]: LanX I don't understand the question though, you want to know what is taking so much space?
[Tanktalus]: Probably the swapfile :)

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (13)
As of 2017-09-20 16:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    During the recent solar eclipse, I:









    Results (237 votes). Check out past polls.

    Notices?