Add comments. Switch .post to .ajax. Add error handler for query ajax.
Fix typo.
Add post attribute to query ajax.
Merge pull request #20 from eugmill/tidy-up-js

Tidy up js