Small corrections

IPTC data are in the first element of array.
GPS coordinate helper added to required files.
This commit is contained in:
Quentin Ligier 2016-04-17 22:23:05 +02:00
parent ea7bfa606e
commit 7841cad8f2
2 changed files with 5 additions and 4 deletions

View File

@ -771,10 +771,10 @@ final class Photo {
// Position // Position
$fields = array(); $fields = array();
if (!empty($iptcInfo['2#090'])) $fields[] = trim($iptcInfo['2#090']); if (!empty($iptcInfo['2#090'])) $fields[] = trim($iptcInfo['2#090'][0]);
if (!empty($iptcInfo['2#092'])) $fields[] = trim($iptcInfo['2#092']); if (!empty($iptcInfo['2#092'])) $fields[] = trim($iptcInfo['2#092'][0]);
if (!empty($iptcInfo['2#095'])) $fields[] = trim($iptcInfo['2#095']); if (!empty($iptcInfo['2#095'])) $fields[] = trim($iptcInfo['2#095'][0]);
if (!empty($iptcInfo['2#101'])) $fields[] = trim($iptcInfo['2#101']); if (!empty($iptcInfo['2#101'])) $fields[] = trim($iptcInfo['2#101'][0]);
if (!empty($fields)) $return['position'] = implode(', ', $fields); if (!empty($fields)) $return['position'] = implode(', ', $fields);

View File

@ -22,6 +22,7 @@ require(__DIR__ . '/autoload.php');
require(__DIR__ . '/helpers/fastImageCopyResampled.php'); require(__DIR__ . '/helpers/fastImageCopyResampled.php');
require(__DIR__ . '/helpers/generateID.php'); require(__DIR__ . '/helpers/generateID.php');
require(__DIR__ . '/helpers/getExtension.php'); require(__DIR__ . '/helpers/getExtension.php');
require(__DIR__ . '/helpers/getGPSCoordinate.php');
require(__DIR__ . '/helpers/getGraphHeader.php'); require(__DIR__ . '/helpers/getGraphHeader.php');
require(__DIR__ . '/helpers/getHashedString.php'); require(__DIR__ . '/helpers/getHashedString.php');
require(__DIR__ . '/helpers/hasPermissions.php'); require(__DIR__ . '/helpers/hasPermissions.php');