0

I am sending emails from my iPhone app by calling a web service and in the email body I need to send a URL that contains an ampersand symbol (&). If I use the symbol in my URL the web service does not send the email, but if I remove that ampersand symbol everything works and the webservice sends the email just fine. So my question is, should I use the ASCII eqivalent of that symbol ? And if so, what is the ASCII eqivalent for '&'? Can any one help me?

This is my URL which has the ampersand symbol

http://xx.xxx.1.xx/xxx/aspxapprvcontrct.aspx?PartyEMail=xx@xxxx.com&devid= 1xx23

Thanks in advance.

Perception
  • 79,279
  • 19
  • 185
  • 195
Ravi
  • 1,759
  • 5
  • 20
  • 38

1 Answers1

0

You need to escape the whole string (email body) you are sending to your webservice. This question has been asked before on SO, see the link included below. I got it from the link @Caleb included, which in and of itself does not solve your particular problem. I would recommend looking at the second answer posted by @Michael Waterfall.

Objective C HTML escape/unescape

Community
  • 1
  • 1
Perception
  • 79,279
  • 19
  • 185
  • 195