in reply to append an expression to a file on remote host

Possible it is indeed.
  • Comment on Re: append an expression to a file on remote host

Replies are listed 'Best First'.
Re^2: append an expression to a file on remote host
by chennaiite (Sexton) on Sep 01, 2005 at 05:31 UTC
    Hi, If you have access to the remote machine you can use a simple open method.
    you can go through this code and have some idea....
    Authentication of the remote is also should be there....
    $hostname ="testing";#it may be ip address or remote host name $hostfilename="temp\fooo.ini"; $hostfilename =~ s/\\/\\\\/g; my $file="\\\\$hostname\\$hostfilename"; if(!-f $remotepath){ print "Remote access and add content to remote file\t\Failed"; exit; } else{ #Remote file access open(TEMP,">>$file") or die ("cannot open the remote file '$fi +le':$!"); #Here add your stuff to append data to the remote file close(TEMP); }