Document.writeln()
Schreibt eine Textfolge, gefolgt von einem Zeilenumbruchzeichen, in ein Dokument.
Syntax
document.writeln(line);
Parameters
line
ist eine Zeichenfolge welche eine Textzeile enthält.
Beispiel
document.writeln("<p>enter password:</p>");
Notes
document.writeln ist dasselbe wie document.write
aber fügt einen Zeilenumbruch hinzu.
Note: document.writeln (like document.write) does not work in XHTML documents (you'll get a "Operation is not supported" (
NS_ERROR_DOM_NOT_SUPPORTED_ERR
) error on the error console). This is the case if opening a local file with a .xhtml file extension or for any document served with an application/xhtml+xml MIME type. More information is available in the W3C XHTML FAQ.Spezifikation
Spezifikation | Status | Bemerkung |
---|---|---|
HTML Living Standard Die Definition von 'document.writeln()' in dieser Spezifikation. |
Lebender Standard | |
Document Object Model (DOM) Level 2 HTML Specification Die Definition von 'document.writeln()' in dieser Spezifikation. |
Veraltet |
Browser Kompatibilität
BCD tables only load in the browser