urlencode parameters to fix #20