Get the last modified date of a remote file

前端 未结 8 2131
难免孤独
难免孤独 2020-11-29 02:45

I would like to get the last modified date of a remote file by means of curl. Does anyone know how to do that?

8条回答
  •  暗喜
    暗喜 (楼主)
    2020-11-29 02:59

    From php's article:

    
    

    filemtime() is the key here. But I'm not sure if you can get the last modified date of a remote file, since the server should send it to you... Maybe in the HTTP headers?

提交回复
热议问题