Nav list bug fix

As pointed out on stack overflow, the nav element had an extra </li>.
Also renamed some JS functions.