简体   繁体   English

php-opendir,强制列出隐藏文件(ftp)

[英]php - opendir, force listing hidden files (ftp)

How to force listing hidden files with ftp connection in PHP script? 如何在PHP脚本中强制使用ftp连接列出隐藏文件? Is there any context option for opendir? opendir是否有任何上下文选项?

Thanks 谢谢

"ftp_rawlist — Returns a detailed list of files in the given directory" (raw => ALL incl. hidden) “ ftp_rawlist —返回给定目录中文件的详细列表”(raw => ALL incl。hidden)

https://secure.php.net/manual/en/function.ftp-rawlist.php https://secure.php.net/manual/zh/function.ftp-rawlist.php


There is one comment to the ftp_rawlist : ftp_rawlist有一条评论

Get a listing of all files including hidden files except '.' 获取所有文件的列表,包括除“。”以外的隐藏文件。 or '..' use: 或“ ..”使用:

 <?php ftp_chdir($connid, $dir); ftp_rawlist($connid, "-A"); ?> 

This had me dancing in circles for some time! 这让我在圈子里跳舞了一段时间!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM