in reply to How to Execute unix commands like "WC, tail, Gunzip, ZIP" against a file which is read from directory
chdir($dir) [download]
system("wc -l $dir/$file") [download]