title: jquery ID select depending on user click of URL
body: <p>Here is Mycode:</p>
  
  <pre><code>$(document).ready(function() {
  
              $("#myLink1").click(function(){
              Foo Bar...
  
          });
      });
  
  &lt;a href = "#" id="myLink1"&gt; click my Link &lt;a&gt;
  
  &lt;a href = "#" id="myLink2"&gt; click my Link2 &lt;a&gt;
  
  &lt;a href = "#" id="myLink3"&gt; click my Link3 &lt;a&gt;
  </code></pre>
  
  <p>for the first one fine, instead of repeating code, how can i capture what user clicked, for say if user clicked 2 or 3 #mylink1 has to be some how replaced is there any generic way??? please help me</p>