Adding a wrapper function for htmlentities which makes it multibyte-friendly