correctly go back to pages that have a parameter in the url