Make WordPress Core


Ignore:
Timestamp:
03/25/2014 12:52:48 PM (8 years ago)
Author:
nacin
Message:

Allow XML attributes with colons to be read by kses.

The attribute would still need to be whitelisted to get through the filters.

props jorbin.
fixes #17847.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/kses.php

    r27388 r27707  
    764764            case 0 : # attribute name, href for instance
    765765
    766                 if (preg_match('/^([-a-zA-Z]+)/', $attr, $match)) {
     766                if ( preg_match('/^([-a-zA-Z:]+)/', $attr, $match ) ) {
    767767                    $attrname = $match[1];
    768768                    $working = $mode = 1;
    769                     $attr = preg_replace('/^[-a-zA-Z]+/', '', $attr);
     769                    $attr = preg_replace( '/^[-a-zA-Z:]+/', '', $attr );
    770770                }
    771771
Note: See TracChangeset for help on using the changeset viewer.