title: How to escape a JSON string to have it in a URL?
body: <p>Using Javascript, I want to generate a link to a page. The parameters to the page are in a Javascript array that I serialize in JSON.</p>
  
  <p>So I would like to generate a URL like that :</p>
  
  <pre><code>http://example.com/?data="MY_JSON_ARRAY_HERE"
  </code></pre>
  
  <p><strong>How do I need to escape my JSON string (array serialized) to include it as a parameter in a URL ?</strong></p>
  
  <p>If there's a solution using JQuery I'd love it.</p>
  
  <p><em>Note: Yes, the parameters to the page need to be in an array because there are a lot of them. I think I'll use bit.ly to shorten the links afterwards.</em></p>