For a Firefox-based kiosk system I’m using an iframe to include the website of the client. The Windows 7 keyboard proves to perform very bad, so he asked for an javascript on-screen keyboard.
As it s开发者_开发知识库tands now, I can’t access the websites input elements via an onclick event listener to show the keyboard and add the characters, as Firefox enforces a same-origin policy.
Are there any other possibilities how to tackle that task?
the only real crossbrowser interaction between windows of not the same origin is by chaning the hash, on which you can react to with javascript. But it would mean, that your client would have to implement a script as well. There are other possibilities to break the same origin policy (like postMessage) but none works out of the box without tweaks to both websites.
Is it possible for you to use Greasemonkey or do you need to leave Firefox alone? This way you can set Greasemonkey to run local scripts that can interact with all your sites.
精彩评论