]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
Fixes #4173 removed use of \w since it is locale sensitive
authorcash <cash.costello@gmail.com>
Wed, 7 Dec 2011 03:05:48 +0000 (22:05 -0500)
committercash <cash.costello@gmail.com>
Wed, 7 Dec 2011 03:05:48 +0000 (22:05 -0500)
engine/lib/output.php

index 60bcc72cd0b4be9d25911aab3b12653d1ed32715..989eca60edcb72122587a512b2aba23f0095e4e1 100644 (file)
@@ -306,6 +306,9 @@ function elgg_get_friendly_title($title) {
        }
 
        //$title = iconv('UTF-8', 'ASCII//TRANSLIT', $title);
+
+       // use A-Za-z0-9_ instead of \w because \w is locale sensitive
+       $title = preg_replace("/[^A-Za-z0-9_ ]/", "", $title);
        $title = preg_replace("/[^\w ]/", "", $title);
        $title = str_replace(" ", "-", $title);
        $title = str_replace("--", "-", $title);