In php manual fileatime is defined as 'last access time of a file'.But in my code ,i opened and read the file content.But fileatime gives me a date back to february 16.Which means i last accessed the file in february 16 ??.But i accessed the file right now.Why it is not giving me the current date??
set_include_path('c://Users/shimantta/Desktop/');
$file='hehe.txt';
$open=fopen($file,'r');
echo fread($open,filesize($file)).'</br>';
echo "Last modified: ".date("F d Y H:i:s.",filemtime($file)).'</br>';
echo "Last modified: ".date("F d Y H:i:s.",fileatime($file)).'</br>';
echo "Last modified: ".date("F d Y H:i:s.",filemtime($file));
i am going to be copied here
Last modified: February 21 2015 19:57:21.
Last modified: February 16 2015 05:56:16.
Last modified: February 21 2015 19:57:21.