ADDED separate js. UPDATED html. UPDATED script with jslint recommendations.