Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Changing FTP Port 1

Status
Not open for further replies.

timtrust123

Programmer
Dec 19, 2003
19
GB
Yes I know......Its beginner stuff but that what i am...

I need to change that port address on a FTP connection but seem unable to do it. My code looks like

$ftp = Net::FTP->new(hostname);
$ftp-> port(6667);
$ftp->login(username, password) ;

Please please help
 
What error are you getting when you turn debug on?

Are you 100% certain your ftp server is responding on that port and visible to the server that the script is running on?
 
Thanks to siberian for advice. Checked FTP server and all well there. My code should have looked like
$ftp = Net::FTP->new($hostname ,Port => "6667")
All working correclty now.
Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top