aspose file tools*
The moose likes JSF and the fly likes 'F1' key binding in jSF Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark " Watch " New topic
Author

'F1' key binding in jSF

jazz jazz
Greenhorn

Joined: Mar 22, 2009
Posts: 2
Hi All

I am a new comer to JSF.
I am working on an issue where i need to bind a key component.
The scenario is when the user clicks on 'F1' in a jsf environment a help page should open.

Can somebody please guide me how to capture the 'F1' key press event so that i can open a help page.



~Keep Smiling
Bauke Scholtz
Ranch Hand

Joined: Oct 08, 2006
Posts: 2458
For starters:
1) Java/JSP/JSF runs at the server machine.
2) Java/JSP/JSF generates and produces a HTML/CSS/JS page.
3) Server machine sends HTML/CSS/JS page to the client machine.
4) Client retrieves HTML/CSS/JS and displays HTML/CSS and runs JS.

So when you want to capture keys in the client side, you need to look for the solution in the HTML/CSS/JS corner. HTML is a markup language, it can't do anything for you. CSS is a styling language, it can't do anything for you. JS (Javascript) is a scripting languate which can intercept on client events, so it's the only which can be of means for you.

Google "javascript capture function keys" or something smart like that for answers. There is also a javascript forum around here for the case you stucks.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61204
    
  66

"jazz jazz", please check your private messages for an important administrative matter.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: 'F1' key binding in jSF