Creating a shortcut key for the letter j to redirect to a url using jquery -


Using jQuery (if it helps), I would like to create a shortcut key for j , so when someone clicks on the letter J , it redirects to a webpage.

Is this possible?

The short answer is yes, this is possible.

Just force if you want it to be a universal shortcut

  $ (document) .keypress (function (event) {if (event.which === 106) {window.location = 'your_url';}});  

Remember to make users very clear that this will happen. There is nothing more than putting a user, who does not exist in place of triggering an order.


Comments

Popular posts from this blog

MySql variables and php -

php - Laravel - Overriding a resource route into a different route filter group -

url rewriting - How to implement the returnurl like SO in PHP? -