• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 688
  • Last Modified:

URGRENT: Need help with key press emulation

Hi,

Is there a way to emulate the F11 key using jQuery?

Thanks in advance.
0
WebAppDeveloper
Asked:
WebAppDeveloper
  • 3
  • 2
3 Solutions
 
HainKurtSr. System AnalystCommented:
0
 
irocwebsCommented:
Here is a simple plug in that I use - easy to implement:
 
http://binarykitten.me.uk/dev/jq-plugins/259-jquery-keyz-plugin.html
0
 
WebAppDeveloperAuthor Commented:
This is what I need to do.....

Onload of the page, I want the page to simulate a user pressing the F11 key. In other words, I need the onload function of the page to automatically press the F11 key for me (without the user doing anything).

Thanks.
0
The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

 
irocwebsCommented:
What is it you are trying to accomplish? Messing with users browsers is a bad idea. Most users can't figure out the difference between their address bar and the their search bar, let alone how to return their screen back to normal size without closing it out completely. Could you do acheive the same thing using Shadow Box (http://shadowbox-js.com/) or full screen in a new window like this?

<script type="text/javascript">
<!--
function popup(url)
{
 params  = 'width='+screen.width;
 params += ', height='+screen.height;
 params += ', top=0, left=0'
 params += ', fullscreen=yes';

 newwin=window.open(url,'windowname4', params);
 if (window.focus) {newwin.focus()}
 return false;
}
// -->
</script>

<a href="javascript: void(0)" onclick="popup('http://www.google.com')">Fullscreen Window</a>
0
 
WebAppDeveloperAuthor Commented:
irocwebs,

I apologize. It was the F9 key that I want to simulate, NOT the F11 key.  The requirement is that I have a third party program that has been configured to run only when the user presses the F9 key, and I need some javascript onload function to automatically (programmatically) simulate the user pressing the F9 key when the web page is loaded (onload of the page).

Thanks in advance.
0
 
WebAppDeveloperAuthor Commented:
Many tihanks to all of you.  This cannot be done since javascript does NOT allow simulating user pressing computer keys other than key detection.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now