好得很程序员自学网

<tfoot draggable='sEl'></tfoot>

phpis_writable函数怎么用

php is_writable函数用于判断该文件是否可写,is_writable函数的语法是is_writable(file),参数file必需,指规定要检查的文件。

php is_writable函数怎么用?

作用:判断该文件是否可写

语法:

is_writable(file)

参数:

file必需。规定要检查的文件。

说明:

如果文件存在并且可写则返回 true。file 参数可以是一个允许进行是否可写检查的目录名。

php is_writable()函数 示例

<?php
$file = is_writable("./test.txt");
if($file == 1)
{
    echo "该文件是可写的";
}else{
    echo "该文件不可写";
}
?>

以上就是php is_writable函数怎么用的详细内容,更多请关注Gxl网其它相关文章!

查看更多关于phpis_writable函数怎么用的详细内容...

  阅读:40次