From: Brion Vibber Date: Tue, 4 Sep 2012 23:47:25 +0000 (-0500) Subject: Fix exif timestamp bug X-Git-Tag: 1.31.0-rc.0~22463 X-Git-Url: http://git.cyclocoop.org/?a=commitdiff_plain;h=a8f5771c82b2f1c12733513c82dc986be5803d7d;p=lhc%2Fweb%2Fwiklou.git Fix exif timestamp bug Missing a prefixed 0 on the hour for some reason, explodes. Change-Id: I8658223d36404e73b9b4d28ce027c1abf98b3f8f --- diff --git a/includes/media/FormatMetadata.php b/includes/media/FormatMetadata.php index 35305d1776..691440228e 100644 --- a/includes/media/FormatMetadata.php +++ b/includes/media/FormatMetadata.php @@ -100,7 +100,7 @@ class FormatMetadata { ) { continue; } - $tags[$tag] = intval( $h[0] / $h[1] ) + $tags[$tag] = str_pad( intval( $h[0] / $h[1] ), 2, '0', STR_PAD_LEFT ) . ':' . str_pad( intval( $m[0] / $m[1] ), 2, '0', STR_PAD_LEFT ) . ':' . str_pad( intval( $s[0] / $s[1] ), 2, '0', STR_PAD_LEFT );