将“%20”传递给字符串以编码为URL而不转换为空格?

I have the following code to post data to a site: https://play.golang.org/p/e1g0Nd1kDh0

When I view the request in Fiddler, it shows as:

"jobTitle=Area Manager"

What I want it to do is send the string exactly as it is in the code (i.e. not encode the %20 to spaces), as it seems to be causing some confusion on the other side? An identical request made using a Python program works fine where the spaces are not added.

I've tried escaping it by doubling the % signs, but it doesn't seem to work. Any help would be great.

Thanks.

If you're trying to receive a literal %20 on the server side, then encode the % sign. It encodes to %25. So your postdata becomes:

    data := "&jobTitle=Area%25%20Manager"

But if this is happening, there is probably a problem on the server side where the postdata is being decoded twice.