最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
php is_file 判断文件存在
时间:2011-10-26 编辑:简简单单 来源:一聚教程网
//用户判断文章是否存 is_file file_exists函数实现
代码如下 | 复制代码 |
function isFile($path) { if( file_exists($path) && is_file($path)) { return true; } else { return false; } } |
//注意is_file 与 file_exists函数不能判断绝对路径如我上面的$_path ='/upfile/'就会显示找不到文件,如果用../upfile/就OK了,
相关文章
- xampp怎么运行php文件 02-24
- php文件怎么打开?php文件打开教程 02-24
- php 格式种子文件怎么打开 02-23
- php怎么打开exe文件 php文件中如何调用在服务器上的exe文件 02-23
- php文件怎么打开 如何执行php文件 02-22
- php格式怎么打开?php格式种子文件怎么打开 02-22