By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,695 Members | 1,638 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,695 IT Pros & Developers. It's quick & easy.

Load URL on key press

P: 1
Hi guys please help me.

I am very very new to javascript.(I do Action script in flash).
here is my problem:

if I press 123 or 589 or anyother 3 digits,the webpage will load another URL.

Like if i press 201 go to google,202 go to yahoo,203 goto.....etc(i need 10 combinations)

how we can don this?is it possible without showing an input field in html page?


reply will be highly appreciated..............thanks in advance.
Jun 12 '07 #1
Share this Question
Share on Google+
2 Replies


acoder
Expert Mod 15k+
P: 16,027
Changed thread title.
Jun 12 '07 #2

acoder
Expert Mod 15k+
P: 16,027
You can use the onkey... events, e.g. onkeypress.

Apply that to the body instead of an input box.
Jun 12 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.