attempt at escaping url from paths correctly