X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_ecrire%28%22articles%22%2C%22id_article=%24id_article%22%29%20.%20%22?a=blobdiff_plain;f=includes%2Fparser%2FCoreParserFunctions.php;h=07944d464896468eafd8f4d3a9d3b1e12d0639a0;hb=f9d4f53105e5883862860724f8399e2d2ab734a1;hp=bb0072c037b59b760170115721828f560a113b1e;hpb=962529515d74517bd936bcb4546cecb5d28cdd91;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/parser/CoreParserFunctions.php b/includes/parser/CoreParserFunctions.php index bb0072c037..07944d4648 100644 --- a/includes/parser/CoreParserFunctions.php +++ b/includes/parser/CoreParserFunctions.php @@ -930,7 +930,8 @@ class CoreParserFunctions { */ public static function anchorencode( $parser, $text ) { $text = $parser->killMarkers( $text ); - return (string)substr( $parser->guessSectionNameFromWikiText( $text ), 1 ); + $section = (string)substr( $parser->guessSectionNameFromWikiText( $text ), 1 ); + return Sanitizer::safeEncodeAttribute( $section ); } public static function special( $parser, $text ) {