store the current page index in location.hash