Use set_url_scheme instead of str_replace