3 ms·
Since there is no universally safe string, it would be better to call it HTMLString (different context such as SQL, e-mail headers, CLI require different types
by pornel 16y ago
Since there is no universally safe string, it would be better to call it HTMLString (different context such as SQL, e-mail headers, CLI require different types of sanitisation).
string.convertToHTML() would escape special characters as HTML entities, preserving the fact that it's just a benign text.