
PHP中readfile()函数读取的文件是和该PHP文件同一目录下的么?
为什么我在和PHP文件同一目录下新建了文本"a.txt"在PHP中写上echoreadfile("a.txt");页面提示Warning:readfile(a.txt):...
为什么我在和PHP文件同一目录下新建了文本"a.txt"
在PHP中写上echo readfile("a.txt");
页面提示Warning: readfile(a.txt): failed to open stream: No such file or directory in D:\xampp\htdocs\zk\search.php on line 11 展开
在PHP中写上echo readfile("a.txt");
页面提示Warning: readfile(a.txt): failed to open stream: No such file or directory in D:\xampp\htdocs\zk\search.php on line 11 展开
2个回答
展开全部
你用什么新建txt文件?直接电脑新建吗?重命名试试,可能你电脑设置了不显示已知扩展名。
echo readfile("a.txt.txt");//试试这样
追问
直接电脑新建、subline另存为都试过……
电脑设置也显示了扩展名……
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询