login about faq

I'm trying to send a "\n". When I use something like: req.AddParam("Body","Line 1 n Line 2")

It gets urlencoded to Line%201%20%5Cn%20Line%202

Instead of keeping the line break. I've also tried to use %0a instead of n and that gets encoded to %250a Is there a way to send a newline?

asked Nov 05 '14 at 20:44

jamesblake's gravatar image


edited Nov 05 '14 at 23:29

Maybe many req.add ? Req.add(line); Req.Add(line); etc


answered Nov 06 '14 at 04:44

GGoul's gravatar image


edited Nov 06 '14 at 04:45

Good idea, but it doesn't work.

(Nov 06 '14 at 12:24) jamesblake

James, I think there is some confusion. The .AddParam is for adding key/value pairs to the URI you will be sending the request to. Because params become part of the URI, multi-line strings may not work. If you are trying to add text to the body of the request, use .LoadBodyFromString instead.



answered Nov 12 '14 at 19:34

emartinson's gravatar image


Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or __italic__
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported



Asked: Nov 05 '14 at 20:44

Seen: 1,231 times

Last updated: Nov 12 '14 at 19:34

powered by OSQA