*/
$wgFixMalayalamUnicode = true;
+/**
+ * Set this to always convert certain Unicode sequences to modern ones
+ * regardless of the content language. This has a small performance
+ * impact.
+ *
+ * See $wgFixArabicUnicode and $wgFixMalayalamUnicode for conversion
+ * details.
+ *
+ * @since 1.17
+ */
+$wgAllUnicodeFixes = false;
+
/**
* Set this to eg 'ISO-8859-1' to perform character set conversion when
* loading old revisions not marked with "utf-8" flag. Use this when
* This is language-specific for performance reasons only.
*/
function normalize( $s ) {
- return UtfNormal::cleanUp( $s );
+ global $wgAllUnicodeFixes;
+ $s = UtfNormal::cleanUp( $s );
+ if ( $wgAllUnicodeFixes ) {
+ $s = $this->transformUsingPairFile( 'normalize-ar.ser', $s );
+ $s = $this->transformUsingPairFile( 'normalize-ml.ser', $s );
+ }
+
+ return $s;
}
/**