fix compliation, add url encoding