I want to add date and time on an image file that I have uploaded. Which way is the best to accomplish this?
Thanks in advance!
Right-click the current time and select the option to "Adjust Date/Time." Choose the option to "Change Date and Time..." and input the new information in the time and date fields. Press "OK" to save your changes and then open the file you want to change.
If you ever want to quickly update the Modified time stamp of a file to the current day and time, right-click that file, select Properties, select the TimeStamps tab, and then click the Touch button. That will instantly change the Last modified entry to the current day and time.
Unfortunately it's not possible to manually change the modified date of any file in Windows.
You can use the touch
function to set the last modified date:
touch("path/to/my-image-file.jpg", $someTimestamp);
To retrieve this in PHP, use filemtime
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With