PHP fileinode() Function

Definition

The fileinode() function returns the inode of the specified file.

Syntax

PHP fileinode() Function has the following syntax.

fileinode(filename)

Parameter

ParameterIs RwuiredDescription
filenameRequired.File to check

Return

This function returns the inode number of the file on success, FALSE on failure.

Note

The result of this function are cached. Use clearstatcache() to clear the cache.

This function doesn't produce useful results on Windows systems.

Example


<?php// www  . j  ava2  s . co  m
$filename = 'test.txt';
if (getmyinode() == fileinode($filename)) {
    echo 'You are checking the current file.';
}

echo fileinode("test.txt");
?>

The code above generates the following result.





















Home »
  PHP Tutorial »
    Function reference »




PHP Array Functions
PHP Calendar Functions
PHP Class Functions
PHP Data Type Functions
PHP Date Functions
PHP File Functions
PHP Image Functions
PHP Math Functions
PHP MySQLi Functions
PHP SimpleXML Functions
PHP String Functions
PHP XML Functions
PHP Zip Functions