jQuery events and iFrames
I've made a jQuery scroll bar ( http://www.liime.net/projects/liimeBar/demo_2.html ) but I've realized it doesn't work when the mouse is in an iFrame for both the m开发者_Python百科ousemove events which is bound to document when someone clicks the scroll button and the mousewheel event (mousewheel plugin) which is also bound to document. Do you have any ideas on how to deal with this?
What I do is use the old opacity 0 trick. Basically, you wrap the iframe inside a container div, which wrap a div (or a readonly textarea) with the opacity 0, which wraps the iframe.
This used to cause some issues on ie, and overall prevent the user to interact with the iframe content, and I'm quite curious if something better has come up since.
check this fiddle
精彩评论