I am trying to find the time that a jpg was created. I am using the
File.atime(file) code. My problem is it will tell me the date that it
was created but the time is 00:00:00, I was wanting to know if anyone
else has ever came across this problem. I am using ruby 1.86
Thanks
Nick
nick wrote:
I am trying to find the time that a jpg was created. I am using the
File.atime(file) code. My problem is it will tell me the date that it
was created but the time is 00:00:00, I was wanting to know if anyone
else has ever came across this problem. I am using ruby 1.86
Thanks
Nick
try mtime
atime is the time last accessed, not created
On Tue, Oct 23, 2007, Citizen S. wrote:
nick wrote:
I am trying to find the time that a jpg was created. I am using the
File.atime(file) code. My problem is it will tell me the date that it
was created but the time is 00:00:00, I was wanting to know if anyone
else has ever came across this problem. I am using ruby 1.86try mtime
atime is the time last accessed, not created
Depending on where the JPEG came from, you might try extracting the EXIF
data too. If the image is coming from a camera, it’s very likely to
have a timestamp for when it was captured.
Search Rubyforge for ‘exif’, there are a number of projects.
Ben
On Oct 23, 9:54 am, Citizen S. [email protected]
wrote:
–
Posted viahttp://www.ruby-forum.com/.
thanks