JavaScript Reference/Javascript Properties/defaultCharset

Материал из Web эксперт
Перейти к: навигация, поиск

"defaultCharset" Example

   <source lang="javascript">
   

<html> <body> <button onclick="alert(document.defaultCharset);">Default Charset</button> </body> </html>


     </source>
   
  


"defaultCharset" is applied to

   <source lang="javascript">

+----------------+--------------------------------------------------------------+ | Applied_To |document | +----------------+--------------------------------------------------------------+

     </source>
   
  


"defaultCharset" Syntax and Note

   <source lang="javascript">

Note: Read-only property. Returns the character set used by the browser.

Syntax:

document.defaultCharset


     </source>