homer.favenir Posted October 30, 2009 Share Posted October 30, 2009 hi, how can i scandir the clients directory? i need a script that when i click a button it will upload all the files in the directory $dir = "\\\\".$_SERVER["REMOTE_ADDR"]."\\NewFolder"; $dir = scandir($dir); foreach($dir as $item){ echo $item; } its not working error: Warning: scandir(\\192.168.200.108\NewFolder) [function.scandir]: failed to open dir: No such file or directory in C:\xampp\htdocs\VYPAdtraq\test\save_success.php on line 43 its in intranet and the folder is already fully shared TIA Link to comment https://forums.phpfreaks.com/topic/179574-scandir-clients-directory/ Share on other sites More sharing options...
seanlim Posted October 30, 2009 Share Posted October 30, 2009 i have never tried scandir on a remote server, but maybe try the ftp protocol with scandir? and make sure that the $_SERVER['REMOTE_ADDR'] ip address really has a NewFolder which has the correct permissions set. Link to comment https://forums.phpfreaks.com/topic/179574-scandir-clients-directory/#findComment-947628 Share on other sites More sharing options...
homer.favenir Posted October 30, 2009 Author Share Posted October 30, 2009 ftp? on each work station? the scenario is this, all users will access the web app, then the server will scandir the shared folder to upload it to server TIa Link to comment https://forums.phpfreaks.com/topic/179574-scandir-clients-directory/#findComment-947629 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.