re #766: urllib.urlencode() needs str not unicode.

fix issue #766