urlencode: handle failure conditions
add ansicolors