function getExif($img){ $exif = exif_read_data($img, ‘IFD0‘); return array ( ‘文件名‘ => $exif[‘FileName‘], ‘器材品牌‘ => $exif[‘Make‘], ‘器材‘ => $exif[‘Model‘], ‘快门‘ => $exif[‘ExposureTime‘], ‘光圈‘ => $exif[‘FNumber‘], ‘焦距‘ => $exif[‘FocalLength‘], ‘感光度‘ => $exif[‘ISOSpeedRatings‘] ); } #extension = "mbstring.so" #extension = "exif.so" $exifInfo = getExif(‘a.jpg‘); echo ‘<pre>‘; print_r($exifInfo); echo ‘</pre>‘;
时间: 2024-11-07 00:03:44