Changed htmlspecialchars to ENT_QUOTES ENT_SUBSTITUTE