Last modified: 2009-05-18 20:21:39 UTC
Numbers in the EXIF data block on image description pages are always rendered in English format instead of the format of the user's preferred language. The relevant code seems to be function formatNum on line 1082 of Exif.php, which is 01082 function formatNum( $num ) { 01083 $m = array(); 01084 if ( preg_match( '/^(\d+)\/(\d+)$/', $num, $m ) ) 01085 return $m[2] != 0 ? $m[1] / $m[2] : $num; 01086 else 01087 return $num; 01088 } It rather should be 01082 function formatNum( $num ) { 01083 global $wgLang; 01084 $m = array(); 01085 if ( preg_match( '/^(\d+)\/(\d+)$/', $num, $m ) ) 01086 return $wgLang->formatNum( $m[2] != 0 ? $m[1] / $m[2] : $num ); 01087 else 01088 return $wgLang->formatNum( $num ); 01089 } Thanks
Please provide a patch for SVN trunk.
A patch? I'm not a MediaWiki programmer. I don't know how a patch has to look like. I provided the code that fixed the issue for my local installation above.
Created attachment 6030 [details] patch A patch per comment#0. The patch however doesn't work for "Exif version" field and the fraction (x/xxx) in "Exposure time" field.
Applied in r50689. Thanks.
r50748 fixes the exposure time fraction.