How to use filemtime function

藏色散人
Release: 2023-04-05 08:52:01
Original
3034 people have browsed it

php filemtime() function is used to obtain the file modification time.

How to use filemtime function

php filemtime() function Syntax

Function: Return the last modification time of the file content.

Syntax:

filemtime(filename)
Copy after login

Parameters:

filename required. Specifies the documents to be checked.​

Note: If successful, the time will be returned as a Unix timestamp. On failure, returns false.

php filemtime() function example

<?php
$file = filemtime("./test.txt");
echo "文件上一次修改的时间为:".$file;
?>
Copy after login

This article is an introduction to the PHP filemtime function. I hope it will be helpful to friends in need!

The above is the detailed content of How to use filemtime function. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!