No spaces after (casts)
[lhc/web/wiklou.git] / includes / Sanitizer.php
index 1432a8b..1d20f18 100644 (file)
@@ -389,10 +389,10 @@ class Sanitizer {
                                'kbd', 'samp', 'data', 'time', 'mark'
                        );
                        $htmlsingle = array(
-                               'br', 'hr', 'li', 'dt', 'dd'
+                               'br', 'wbr', 'hr', 'li', 'dt', 'dd'
                        );
                        $htmlsingleonly = array( # Elements that cannot have close tags
-                               'br', 'hr'
+                               'br', 'wbr', 'hr'
                        );
                        if ( $wgAllowMicrodataAttributes ) {
                                $htmlsingle[] = $htmlsingleonly[] = 'meta';
@@ -1548,6 +1548,9 @@ class Sanitizer {
                        # 9.3.2
                        'br'         => array( 'id', 'class', 'title', 'style', 'clear' ),
 
+                       # http://www.whatwg.org/html/text-level-semantics.html#the-wbr-element
+                       'wbr'        => array( 'id', 'class', 'title', 'style' ),
+
                        # 9.3.4
                        'pre'        => array_merge( $common, array( 'width' ) ),
 
@@ -1799,6 +1802,6 @@ class Sanitizer {
                $                      # End of string
                /ix"; // case Insensitive, eXtended
 
-               return (bool) preg_match( $HTML5_email_regexp, $addr );
+               return (bool)preg_match( $HTML5_email_regexp, $addr );
        }
 }