Override query and hash fragment components when redirecting