Changed the javascript to allow for the page to change without refreshing the page by using push and pop.