If you just want a plain vanilla Javascript way, you can use the following:
var iframe = document.getElementById('myIFrame');
iframe.contentDocument.body.addEventListener('mouseup', Handler);
function Handler() {
alert('works');
}
More Related Contents:
- jQuery Event Keypress: Which key was pressed?
- How to capture the browser window close event?
- Definitive way to trigger keypress events with jQuery
- How to order events bound with jQuery
- Firing event on DOM attribute change
- Can I call jQuery’s click() to follow an link if I haven’t bound an event handler to it with bind or click already?
- What is the difference between the mouseover and mouseenter events?
- How to trigger the window resize event in JavaScript?
- Difference between “change” and “input” event for an `input` element
- Resize event for textarea?
- How do you log all events fired by an element in jQuery?
- How to unbind a listener that is calling event.preventDefault() (using jQuery)?
- Jquery: change event to input file on IE
- Preventing click event with jQuery drag and drop
- jQuery: How to get the event object in an event handler function without passing it as an argument?
- Attach an event in a child iframe to a handler in the parent window
- Javascript with jQuery: Click and double click on same element, different effect, one disables the other
- Changing the keypress
- jQuery: Unbind event handlers to bind them again later
- jQuery prevent change for select
- jQuery event that triggers after CSS is loaded?
- Performance difference between jQuery’s .live(‘click’, fn) and .click(fn)
- Get the clicked object that triggered jquery blur() event [duplicate]
- Drop event not firing in chrome
- How to unbind a specific event handler
- Capture event onclose browser
- List all javascript events wired up on a page using jquery
- Jquery: mousedown effect (while left click is held down)
- jQuery: How to listen for DOM changes?
- Unloading/Removing content from an iFrame