How can I programmatically generate keypress events from Javascript code running in Safari? It looks like WebKit is using the DOM level 3 model for creating keyboard events
http://docs.jquery.com/Events/keypress#fn
In other words, you attach a keypress event to some element. Using an element with the ID of "someid", for example: