PHP » PYTHON |
login |
register |
about
|
import os statinfo = os.stat(filename) stat(PHP 4, PHP 5) stat — Gives information about a file Description
array stat
( string $filename
)
Gathers the statistics of the file named by filename . If filename is a symbolic link, statistics are from the file itself, not the symlink. lstat() is identical to stat() except it would instead be based off the symlinks status. Parameters
Return Values
* On Windows this will always be 0. ** Only valid on systems supporting the st_blksize type - other systems (e.g. Windows) return -1. In case of error, stat() returns FALSE. Errors/ExceptionsUpon failure, an E_WARNING is emitted. Changelog
Examples
Example #1 stat() example
<?php
Example #2 Using stat() information together with touch()
<?php
Notes
Tip
As of PHP 5.0.0, this function can also be used with some URL wrappers. Refer to List of Supported Protocols/Wrappers for a listing of which wrappers support stat() family of functionality. See Also
|
more
Recently updated
more
Most requested
more
Last requests
|