I have an anchor defined as follows -
<a onClick="javascript:isLinked('');" class="..." href="..."><img border="0" alt="" height="8" width="8" src="..."/> <u>Add another</u></a>
The javascript function -
function isLinked(sId) {
if(!sId)
{
alert(".....");
return false;
}
else
document.body.style.cursor='wait';
}
Although I do see the alert being triggered on the click of the anchor,the links still follows the target url.
How can i prevent the link from following?
The browser is IE8(if that is relevant)