English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

HTML Referenzhandbuch

Vollständiges Verzeichnis der HTML-Tags

HTML: <form> accept-charset-Eigenschaft

form accept-Die charset-Eigenschaft spezifiziert die Zeichencodierung, die für die Übermittlung des Formulars verwendet wird. Der Standardwert ist der reservierte String "UNKNOWN" (was bedeutet, dass die Codierung der Codierung entspricht, die im Dokument enthalten ist, das den <form>-Element enthält).

 HTML <form> Tag

Online-Beispiel

mit accept-Formular charset-Eigenschaft:

!DOCTYPE html
<html>
<head>
<meta charset="utf-8">
<title>HTML <form> accept-charset-Eigenschaft verwenden-Basis-Tutorial(oldtoolbag.com)</title>
</head>
<body>
<form action="action_page.php" accept-charset="ISO-8859-1">
  Vorname: <input type="text" name="fname"><br>
  Nachname: <input type="text" name="lname"><br>
  <input type="submit" value="Submit">
</form>
</body>
</html>
Testen Sie, ob ‹/›

Browser-Kompatibilität

IEFirefoxOperaChromeSafari

All mainstream browsers support accept-charset Attribute

Definition and Usage

accept-The charset attribute specifies the character encoding used for form submission.
The default value is the reserved string 'UNKNOWN' (indicating that the encoding is equal to the encoding of the document containing the <form> element).

HTML 4.01 with HTML5differences

In HTML 4.01In, the character encoding list can be separated by spaces or commas. In HTML5In, the list must be separated by spaces.

Syntax

<form accept-charset="character_set">

Attribute Value

ValueDescription
character_setList of character encodings used when submitting a form, multiple character encodings are separated by spaces.

Common Values:

  • UTF-8 - Unicode Character Encoding

  • ISO-8859-1 - Character Encoding of the Latin Alphabet

In theory, any character encoding can be used, but no browser can understand all encodings. The more widely a character encoding is used, the better the browser supports it.

To view all available character encodings, please visit our Character Encoding Reference Manual.

 HTML <form> Tag