more best practices based on Kyo's work
Merge pull request #26 from rusvika/master

updates to XSS protection