changed html and added explanations to code