How to get link url from javascript
<p>I have the following code :</p>

<pre><code>&lt;?php
$i = 0;
foreach($this-&gt;list as $l) { 
$link = JRoute::_("index.php?option=com_ecommerce&amp;view=detail&amp;id=$l-&gt;id");
&lt;div class="quickview" id="quickview_&lt;?php echo $i;?&gt;"&gt;
&lt;a href='&lt;?php echo $link ?&gt;' class='basic'&gt;Quick view&lt;/a&gt;
&lt;/div&gt;
i++;
}
?&gt;
&lt;script&gt;
jQuery(function ($){
    var link = $('.quickview .basic').val();
    $('.quickview .basic').click(function (e) {
    alert(link);
        return false;
    });
});
&lt;/script&gt;
</code></pre>

<p>I can't get link from tag <code>&lt;a&gt;</code>, please help me!</p>
