title: Javascript add ID to HTML href
body: <p>I have a livesearch script that i need to populate my html menu with information.</p>
  
  <p>i have a menu how looks something like this:</p>
  
  <pre><code>&lt;a href="?page=page&amp;id="&gt;Menu item&lt;/a&gt;
  </code></pre>
  
  <p>what i'm looking for is a piece of code that would do this to the link:</p>
  
  <pre><code>&lt;a href="?page=page&amp;id=1"&gt;Menu item&lt;/a&gt;
  </code></pre>
  
  <p>i have a Javascript that pulls out value ID from a database table (livesearch), now i only need it to get into the href on the fly.</p>
  
  <p>Any suggestions?</p>