By the way, regexes weren't needed here at all.
Change-Id: I41d222a4d60ead3655f7565b6703186abcd223e0
$text = htmlspecialchars( $text );
// encode all comments or tags as safe blue strings
- $text = preg_replace( '/\<(!--.*?--|.*?)\>/', '<span style="color:blue;"><\1></span>', $text );
+ $text = str_replace( '<', '<span style="color:blue;"><', $text );
+ $text = str_replace( '>', '></span>', $text );
// identify URLs
$protos = wfUrlProtocolsWithoutProtRel();
// This regex hacks around bug 13218 (" included in the URL)