LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 08-05-2003, 11:11 AM   #1
letmein
LQ Newbie
 
Registered: Jul 2003
Posts: 24

Rep: Reputation: 15
perl + ftp


hi

i am writing a perl script to connect tomy FTP server, i am using perl-5.8.0
& heres how my code looks...

require "ftp.pl;
$FtpHost = "134.88.147.226";
if (&ftp:pen($FtpHost,21,0,1)!= 1)
{
die "Can't open $FtpHost\n";
}
if (&ftp:login("test1","test1") != 1) {
die "Can't Login to $FtpHost\n";
}
&ftp::close;



but i am getting an error , "chat2.pl" not found something like this ...
can anyone tell whats wrong?
 
Old 08-05-2003, 01:56 PM   #2
stickman
Senior Member
 
Registered: Sep 2002
Location: Nashville, TN
Posts: 1,552

Rep: Reputation: 53
Looks like your missing "chat2.pl". You can probably get it from the same place as ftp.pl. Have you tried using Net::FTP?

Last edited by stickman; 08-05-2003 at 01:57 PM.
 
Old 08-06-2003, 02:15 PM   #3
letmein
LQ Newbie
 
Registered: Jul 2003
Posts: 24

Original Poster
Rep: Reputation: 15
yah ...

it works perfectly fine with Net::FTP


use Net::FTP;
$ftp = Net::FTP->new('134.88.147.226','Debug', 10);
$ftp->login('test1','test1');
$ftp->quit;


works good for me ....
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Urgent Help: Perl FTP Script Using NET::FTP xboxter Programming 8 05-16-2005 06:57 PM
RH8 with perl ftp across firewall mairot Linux - Networking 1 11-29-2004 02:37 PM
perl and Net::FTP question Tomasfuego Programming 0 12-17-2003 08:13 AM
perl, Net::Ftp, and Novell file modification time neo77777 Programming 0 01-30-2003 09:41 PM
perl NET::FTP binary mode lackluster Programming 5 07-18-2002 06:30 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 10:24 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration