update regex to remove parameters of url.