2013-01-29 02:28:49 8 Comments
This isn't Twilio specific, but the issue does cause the Twilio API call to fail..
I'm wanting to generate an XML file via Twilio's lab:
http://twimlets.com/echo?Twiml=%3CResponse%3E%3CSay%3EHi+there.%3C%2FSay%3E%3C%2FResponse%3E
The above URL works great as a parameter in the API and obviously works if you use your browser to view the output.
I can also view the following in the browser, and it works fine, but this version of the URL fails as a parameter to the Twilio API
http://twimlets.com/echo?Twiml=Response><Say>Hi+there.</Say></Response>
For readability and debugging I would much prefer to have the second URL. Is there a library or other way in C# to convert the second, pretty URL to the first, replacing %3C with the '<' character and so on? I could then just do the replacement right before I send it off to the API since my app pushes around and stores the pretty version everywhere else. I can of course write one myself to do the conversion, but it seems like this would be a common problem. Thanks!
Related Questions
Sponsored Content
20 Answered Questions
[SOLVED] Get the current URL with JavaScript?
- 2009-06-23 19:26:45
- dougoftheabaci
- 2515638 View
- 2673 Score
- 20 Answer
- Tags: javascript url
31 Answered Questions
24 Answered Questions
[SOLVED] Case insensitive 'Contains(string)'
- 2009-01-14 21:39:46
- Boris Callens
- 740587 View
- 2584 Score
- 24 Answer
- Tags: c# string contains case-insensitive
14 Answered Questions
[SOLVED] Encode URL in JavaScript?
- 2008-12-02 02:37:08
- nickf
- 1365760 View
- 2237 Score
- 14 Answer
- Tags: javascript url encoding
57 Answered Questions
73 Answered Questions
[SOLVED] How can I get query string values in JavaScript?
- 2009-05-23 08:10:48
- Kemal Emin
- 3340218 View
- 2702 Score
- 73 Answer
- Tags: javascript url plugins query-string
13 Answered Questions
[SOLVED] How to change the URI (URL) for a remote Git repository?
- 2010-03-12 12:48:47
- e-satis
- 1187821 View
- 3034 Score
- 13 Answer
- Tags: git url git-remote
30 Answered Questions
[SOLVED] Get current URL with jQuery?
- 2009-01-02 06:42:54
- venkatachalam
- 1920998 View
- 1670 Score
- 30 Answer
- Tags: javascript jquery url path
18 Answered Questions
[SOLVED] How to modify the URL without reloading the page?
- 2009-05-05 10:54:05
- Robinicks
- 1129666 View
- 1977 Score
- 18 Answer
- Tags: javascript html url url-rewriting friendly-url
1 comments
@Hanlet Escaño 2013-01-29 02:40:14
Is this perhaps what you are looking for?
Output - Unescaped string:
And back to normal:
Output - escaped string: