Fixed JavaScript - added jQuery and moved external scripts to head
Fixed minor JS error