ExampleExecute a JavaScript when a user releases a key: |
Browser Support |
1. Definition and Usage
The onkeyup attribute fires when the user releases a key (on the keyboard).
Tip: The order of events related to the onkeyup event:
- onkeydown
- onkeypress
- onkeyup
Note: The onkeyup attribute CANNOT be used with: <base>, <bdo>, <br>, <head>, <html>, <iframe>, <meta>, <param>, <script>, <style>, or <title>.
2. Differences Between HTML 4.01 and HTML5
None.
3. Syntax
<element onkeyup="script">
4. Attribute Values
Value | Description |
---|---|
script | The script to be run on onkeyup |