Hi Paul,

Many thanks indeed.  I can see the general idea of your code, but it is way
beyond me.

Would it be very easy to create a cf tag from this that would take an image
and output the exif data, etc?

Thanks again,

Jenny

-----Original Message-----
From: Paul Hastings [mailto:[email protected]] 
Sent: 28 February 2013 02:27
To: cf-talk
Subject: Re: EXF Photo Information


oops, that code was for cf10 & used some undocumented stuff. this might work
better for cf7.

<cfscript>
// path to image on server
path="c:\cyclingTrips\khlong13\coffinService.jpg";
// lib wants java IO file so...
imgFile=createObject("java","java.io.File").init(path);
metadataReader=createObject("java","com.drew.imaging.ImageMetadataReader");
metadata=metadataReader.readMetadata(imgFile);
exifDirs=metadata.getDirectories();
for (i=1; i LTE arrayLen(exifDirs); i++) {
   writeoutput("<b>Dir: #exifDirs[i].getName()#</b><br>");
   tags=exifDirs[i].getTags();
   for (j=1; j LTE arrayLen(tags); j++) {
     writeoutput("#tags[j].getTagName()# :: #tags[j].getDescription()#
<br>");
   }
   writeoutput("================================================<br>");

}       
</cfscript>






~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354730
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to