HTML | DOM inputEncoding Property
The inputEncoding property returns the character encoding used for parsing the document. This property doesn’t have any default value.
Syntax:
document.inputEncoding
Parameters:
Return Value:
Example:
<!DOCTYPE html> <html> <head> <title> HTML | DOM inputEncoding Property </title> </head> <body> <p> Click the button to check the encoding of this document </p> <button onclick="geek()"> Alert document's encoding </button> <script> function geek() { var docEncoding = document.inputEncoding; alert(docEncoding); } </script> </body> </html> |
chevron_right
filter_none
Output :
Before clicking the button:

After clicking the button:

Supported Browsers: The browser supported by DOM inputEncoding() Property are listed below:
- Google Chrome
- Internet Explorer 9.0+
- Firefox
- Opera 15.0+
- Safari
Recommended Posts:
- HTML | DOM id Property
- HTML | DOM dir Property
- HTML | DOM specified Property
- HTML | DOM URL Property
- HTML | DOM name Property
- HTML | DOM value Property
- HTML | DOM Bdo dir Property
- HTML | DOM li value Property
- HTML | DOM domain Property
- HTML | DOM ins cite Property
- HTML | DOM nodeType Property
- HTML | DOM offsetHeight Property
- HTML | DOM clientTop Property
- HTML | DOM ins dateTime Property
- HTML | KeyboardEvent which Property
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.



