Accessing tags with PHP



I have set up f-spot to store the tags in the picture files
themselves. How can I access these tags with PHP? I do know how to
access IPTC tags with PHP but not the tags that f-spot uses. A simple
working code example would be very, very much appreciated.

Also, are the tags UTF-8? If not, what charset are they?

This is the code that I use to access IPTC:
<?php
$size = GetImageSize ("/path/to/pic.jpg", &$info);
$iptc = iptcparse($info["APP13"]);

print "Keywords: ".$iptc["2#025"][0]."<br />";
print "People: ".$iptc["2#118"][0]."<br />";
print "Place: ".$iptc["2#027"][0]."<br />";
print "Event: ".$iptc["2#105"][0]."<br />";
print "Date: ".$iptc["2#055"][0]."<br />";
print "Time: ".$iptc["2#060"][0]."<br />";
?>

Note that the IPTC tags used here are not to standard, they are as per
the excellent windows software BrilliantPhoto.

Dotan Cohen
http://what-is-what.com



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]