- $msg = preg_replace( '/^ /m', '  ', $msg );
- $msg = preg_replace( '/ $/m', '  ', $msg );
- $msg = preg_replace( '/ /', '  ', $msg );
+ $msg = preg_replace( '/^ /m', "\u{00A0} ", $msg );
+ $msg = preg_replace( '/ $/m', " \u{00A0}", $msg );
+ $msg = preg_replace( '/ /', "\u{00A0} ", $msg );