Replace constants in the URL string