in reply to Getting latest file from FTP server

You could use ls -lrt (which reverses the list by time updated). Something like
$tmp = `ls -lrt`; @array = split /\n/,$tmp; print $array[@array-1];
you could do this cleaner with a regexp even.
Good Luck
Josh