php umask 函数教程_PHP教程

WBOY
Release: 2016-07-20 11:01:14
Original
1199 people have browsed it

php umask 函数教程

umask值
( PHP 4中, PHP 5中)

的umask -改变了当前的umask

描述
诠释的umask ( [国际$遮罩] )
的umask ( )设置PHP的umask值,以掩盖和0777并返回旧的umask 。当PHP被用作服务器模块, umask被恢复时,每个请求完成。

参数

遮罩
新的umask 。


返回值
umask值( )不带参数只返回当前的umask否则旧的umask被退还。

实例

例如# 1的umask ( )的例子

$old = umask(0);
chmod("/path/some_dir/some_file.txt", 0755);
umask($old);

// Checking
if ($old != umask()) {
die('An error occured while changing back the umask');
}
?>


www.bkjia.com true http://www.bkjia.com/PHPjc/445464.html TechArticle php umask 函数教程 umask值 ( PHP 4中, PHP 5中) 的umask -改变了当前的umask 描述 诠释的umask ( [国际$遮罩] ) 的umask ( )设置PHP的umask值,以掩...
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!