EagleAmerican Posted July 2, 2008 Share Posted July 2, 2008 How would I get the number of files in an FTP directory? I have it getting to the right directory and logging in and all of that but I need to know how many files are there. Thanks. Quote Link to comment https://forums.phpfreaks.com/topic/112977-solved-number-of-files/ Share on other sites More sharing options...
tomd79 Posted July 2, 2008 Share Posted July 2, 2008 http://uk2.php.net/glob that's what you need I think Quote Link to comment https://forums.phpfreaks.com/topic/112977-solved-number-of-files/#findComment-580327 Share on other sites More sharing options...
rhodesa Posted July 2, 2008 Share Posted July 2, 2008 this will get you the TOTAL count: $count = count(ftp_nlist($conn_id, ".")); do you need just files? aka not directories? if so, what about links? Quote Link to comment https://forums.phpfreaks.com/topic/112977-solved-number-of-files/#findComment-580330 Share on other sites More sharing options...
EagleAmerican Posted July 2, 2008 Author Share Posted July 2, 2008 Just need files, thank you very much! Quote Link to comment https://forums.phpfreaks.com/topic/112977-solved-number-of-files/#findComment-580337 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.