title: How to add a variable to the URL on click?
body: <p>I have a delte link <code>[Delete]</code> which onClick should attach a couple of variables to the URL. </p>
  
  <pre><code>&lt;a id="close-frame-course" href="action=#?delete_course&amp;course_id=&lt;?php echo $courseid[$count]; ?&gt;"&gt;&lt;div class="close-frame"&gt;X&lt;/div&gt;&lt;/a&gt;
  </code></pre>
  
  <p>The current URL is like <code>example.com/dashboard.php?page=all</code></p>
  
  <p>I was to add <code>action=delete_course&amp;course_id=1</code> upon clicking on the link. But this seems not right. I can't get the values in js. Could you help me to fix it?</p>