Index: trunk/extensions/RecordAdmin/RecordAdmin_body.php |
— | — | @@ -616,7 +616,9 @@ |
617 | 617 | $html = preg_replace( "|(<option[^<>]*) selected|i", "$1", $html ); # remove the currently selected option |
618 | 618 | if( $v ) { |
619 | 619 | foreach( self::split( $v ) as $v ) { |
620 | | - $v = htmlentities( preg_replace( "|([\[\]\|\\\(\)])|", "\\$1", $v ) ); |
| 620 | + $v = htmlentities( $v ); |
| 621 | + $v = str_replace( '(', '\(', $v ); |
| 622 | + $v = str_replace( ')', '\)', $v ); |
621 | 623 | $html = preg_match( "|<option[^>]+value\s*=|is", $html ) |
622 | 624 | ? preg_replace( "|(<option)([^>]+value\s*=\s*[\"']{$v}['\"])|is", "$1 selected$2", $html ) |
623 | 625 | : preg_replace( "|(<option[^>]*)(?=>$v</option>)|is", "$1 selected", $html ); |