Every time a user uploads a new picture, we rename the picture to the value of PHP's time()
function, so our database doesn't have duplicate picture names (because there is no same year, month, day, hour, min and sec).
I need to know whether or not the value of time()
includes the year. If not, then next year will allow duplicated picture names. How do I understand the return value of time()
, for example 1301888225? How do I get year, month, day, etc. information out of that number?