I download Net::FTP module of perl and its working fine
i wrote a program called ftpfile is as follws
#! /usr/bin/perl -w
#ftpfile [servername] [directory] [filename]
use strict;
use Net::FTP;
my $hostname=" ";
my $directory= " ";
my $file_name= " ";
if(scalar @ARGV==0)
{
print "ftpfile [servername][directory][filename]","\n";
exit;
}
my $ftp=Net::FTP ->new($hostname) or die ("connect failed"
$ftp->login("anonymous",'raju_m_in@yahoo.com');
$ftp->binary;
$ftp->cwd("$directory"
$ftp->get("$file_name" or die("No file Found"
$ftp->quit;
exit;
thie program i put in the bin directory of my home and I edit the .bashrc file
in my actual program I am calling this file
though the system commnad and passing the argument
my $ifile="1b25.dssp";
this $ifile I am returning from a sub and it cahnges through $line of foreachloop
in the foreach loop I am using the following line to connect to the database
system "ftpfile ftp.embl-heidelberg.de pub/databases/protein_extras/dssp/ $ifile";
from the same program ealier i used to get the output but my system crashed and I reinstalled everything and try to retrive the files but I am not abel to and it gives me
the error
can not open the file
I am really in need of help can anybody help me
thanks in advance
i wrote a program called ftpfile is as follws
#! /usr/bin/perl -w
#ftpfile [servername] [directory] [filename]
use strict;
use Net::FTP;
my $hostname=" ";
my $directory= " ";
my $file_name= " ";
if(scalar @ARGV==0)
{
print "ftpfile [servername][directory][filename]","\n";
exit;
}
my $ftp=Net::FTP ->new($hostname) or die ("connect failed"
$ftp->login("anonymous",'raju_m_in@yahoo.com');
$ftp->binary;
$ftp->cwd("$directory"
$ftp->get("$file_name" or die("No file Found"
$ftp->quit;
exit;
thie program i put in the bin directory of my home and I edit the .bashrc file
in my actual program I am calling this file
though the system commnad and passing the argument
my $ifile="1b25.dssp";
this $ifile I am returning from a sub and it cahnges through $line of foreachloop
in the foreach loop I am using the following line to connect to the database
system "ftpfile ftp.embl-heidelberg.de pub/databases/protein_extras/dssp/ $ifile";
from the same program ealier i used to get the output but my system crashed and I reinstalled everything and try to retrive the files but I am not abel to and it gives me
the error
can not open the file
I am really in need of help can anybody help me
thanks in advance