<p>My users would like to be able to hit <kbd>Ctrl</kbd>+<kbd>S</kbd> to save a form.  Is there a good cross-browser way of capturing the <kbd>Ctrl</kbd>+<kbd>S</kbd> key combination and submit my form?</p>

<p>App is built on Drupal, so jQuery is available.</p>

```
```
$(window).keypress(function(event) {
    if (!(event.which == 115 && event.ctrlKey) && !(event.which == 19)) return true;
    alert("Ctrl-S pressed");
    event.preventDefault();
    return false;
});
```
```
Key codes can differ between browsers, so you may need to check for more than just 115.