?php $file = fopen ("ftp: / /ftp.example.com / incoming / outputfile", "w"); if (!$file) {echo "p Unable to open remote file for writing.\n"; exit;} / * Write the data here. * / fputs ($file, $_SERVER['HTTP_USER_AGENT']. "\n"); fclose ($file);?
?php $file = fopen( "ftp: / /ftp.php.net / incoming / outputfile", "w"); if (!$file) {echo "p Impossible d'ouvrir un fichier distant en écriture.\n"; exit;} / * Ecriture des données. * / fputs($file, "$HTTP_USER_AGENT\n"); fclose($file);?