Fixed some XSS security issues