Constructing a URL with parameters using jQuery
<p>I have for example the following URL stored in a global variable:</p>

<pre><code>var myUrl = "http://mydomain.com/something?row=1";
</code></pre>

<p>Then a function has to add let's say another parameter called "<em>column</em>". How would that function add parameters to a pre-existing URL string using jQuery?</p>

<p>Example of the expected generated string:</p>

<pre><code>"http://mydomain.com/something?row=1&amp;column=9"
</code></pre>

<p>The problem is that <code>myUrl</code> could also be just:</p>

<pre><code>var myUrl = "http://mydomain.com/something";
</code></pre>

<p>(Notice that there are not pre-existing parameters)</p>
