Make the current url relative if a base url is provided.