jquery div click, anchors


to click-able divs, i do:



<div class="clickable" url="http://google.com">
blah blah
</div>


and following



$("div.clickable").click(
function()
{
window.location = $(this).attr("url");
});


i don't know best way, nonetheless works ideally me, solely issue:
if div contains click-able element, such as
<a href="...">, user clicks hyperlink, both hyperlink div's-clickable called



this generally problem anchor add-on referring javascript ajax function, executes ajax duty and follows couple 'url' charge div.



anyway around this?



Comments

Popular posts from this blog

list macos calm editors formula editors

how i practical urls indicate .aspx pages asp.net deployed an iis? (preferably but iis)

jaxb - xjc - reworking generated typesafe enum category members