1$filename = 'somefile.txt';
2if (file_exists($filename)) {
3 echo "$filename last modified: ".date ("F d Y H:i:s.", filemtime($filename));
4 // somefile.txt was last changed: December 29 2020 22:16:23.
5}
6// filectime: when created
7// filemtime: last modified
8// fileatime: last accessed