Home Tutorial Php Phpfiles The filectime() function, filectime php, filectime() in php

 
 

The filectime() function, filectime php, filectime() in php
Posted on: September 24, 2009 at 12:00 AM
The PHP filectime() Function is used to get the inode change time for a file.

Example of filectime() in PHP

Description

Syntax of filectime() in PHP

int filectime(filename)

It gives the last time when file  was changed.

Changes are meant for inode(user,group,other permission in unix o/s ) and  content 

It returns the time in int if there are changes .Convert them to date format by date function

And FALSE if no changes 

Code of filectime() in PHP

<?php

$time = time();

echo "current date and times is ".date("m/d/y H:i:s ", $time);

echo "<br>current File Access Time is ".date("m/d/y H:i:s ", filectime("c:/rose1/ram.txt"));

?>

Output

current date and times is 09/10/09 10:07:24
current File Access Time is 09/09/09 07:18:31

 

Related Tags for The filectime() function, filectime php, filectime() in php:


Ask Questions?

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.

Ask your questions, our development team will try to give answers to your questions.