Clean up and refactor page links.