PHP » PYTHON |
login |
register |
about
|
PYTHON posix_access
is this article helpful?
|
Python replacement for PHP's posix_access
[
edit
| history
]
import os os.access(file, mode) mode is one of: os.F_OK, os.R_OK, os.W_OK, os.X_OK posix_access(PHP 5 >= 5.1.0) posix_access — Determine accessibility of a file Description
bool posix_access
( string $file
[, int $mode= POSIX_F_OK
] )
posix_access() checks the user's permission of a file. Parameters
Return ValuesReturns TRUE on success or FALSE on failure. Examples
Example #1 posix_access() example This example will check if the $file is readable and writable, otherwise will print an error message.
<?php
Notes
See Also
|
more
Recently updated
more
Most requested
more
Last requests
|