add urlencode to do inplace encode

Signed-off-by: xiehuc <xiehuc@gmail.com>