title: How do browsers display the target url of a link
body: <p>If you do a google search for some string , the browser would render the search results in the form of clickable links. Now here comes my question. If one hovers on those links, at the bottom left hand side, you would be able to see the location where the browser would take you if you hit it. I want to know how the browser does it.</p>
  
  <p>I dont think that search results are actually HTML based anchor tags. Atleast that's what I feel. But even in those cases, the target url gets displayed whenever we hover over the links.</p>
  
  <p>Please share your thoughts on how its done..i need to do the same in a js code.</p>
  
  <p>-->Thanks for your answers. There is a reason why I had to ask this. I have to enable drag and drop between a web page which i am gonna show in an SWT Browser and a java GUI. In order to do that, in the mousedown event, i am firing a javascript code. This basically gets the HREF attribute on the anchor element which the user has clicked. <em>*</em>*Now here is the catch. If I open google.com and if I do a mouse down IMAGE,YOUTUBE,GMAIL,DRIVE links the target URL is coming up fine. But if i try to do a mouse down on any of the results in google search OR in our original thin client application which we need to enable for drag and drop, the link is not coming up. However, the browser at the bottom shows the target link. I am confused. This is the reason why I think it is not an anchor tag.</p>
  
  <p>I tried by registering an onmousedown with the following code for all the anchor elements. But with this if the user does a mousedown on any of the search result...no alert box was coming up.</p>
  
  <pre><code>var elements = document.getElementsByTagName('a');
  for(var i=0;i&lt;elements.length;i++)
  {
      elements[i].onmousedown = function()
      { 
            alert(this.getAttribute('href'));
      }
  } 
  </code></pre>