iframe - Track click on whole HTML page with JQUERY -


i'm trying track click on html element.

with:

$('html').click(function() {     // action here }); 

but thing won't work iframe , coudn't catch iframe click, or click selectionbox

http://jsfiddle.net/tyjtc/4/

this answer based on iframe content of domain, using jquery 1.7.2 , should inside of document ready

http://jsfiddle.net/tyjtc/6/

html

<iframe id="myframe" src='/'></iframe> 

js

$('#myframe').contents().find('body').bind('click', function(e) {     alert('clicked'); }); 

Comments

Popular posts from this blog

django - How can I change user group without delete record -

java - Need to add SOAP security token -

java - EclipseLink JPA Object is not a known entity type -