diff options
author | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:42:52 -0500 |
---|---|---|
committer | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:42:52 -0500 |
commit | 074785cea106179cb3305637055ab0a009ca74f2 (patch) | |
tree | e6ae371cccd642aa2b67f39752a2cdf1fd4eb040 /files/pt-br/web/api/document/writeln/index.html | |
parent | da78a9e329e272dedb2400b79a3bdeebff387d47 (diff) | |
download | translated-content-074785cea106179cb3305637055ab0a009ca74f2.tar.gz translated-content-074785cea106179cb3305637055ab0a009ca74f2.tar.bz2 translated-content-074785cea106179cb3305637055ab0a009ca74f2.zip |
initial commit
Diffstat (limited to 'files/pt-br/web/api/document/writeln/index.html')
-rw-r--r-- | files/pt-br/web/api/document/writeln/index.html | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/files/pt-br/web/api/document/writeln/index.html b/files/pt-br/web/api/document/writeln/index.html new file mode 100644 index 0000000000..ed2efb2b85 --- /dev/null +++ b/files/pt-br/web/api/document/writeln/index.html @@ -0,0 +1,43 @@ +--- +title: Document.writeln() +slug: Web/API/Document/writeln +tags: + - API + - DOM + - Gecko + - Referencia + - metodo +translation_of: Web/API/Document/writeln +--- +<div>{{ ApiRef("DOM") }}</div> + +<p><span id="result_box" lang="pt"><span class="hps">Grava uma seqüência</span> <span class="hps">de</span> <span class="hps">texto</span><span>, seguido</span> <span class="hps">por um</span> <span class="hps">caractere de nova linha</span> <span class="hps">a um documento.</span></span></p> + +<h2 id="Syntax" name="Syntax">Sintaxes</h2> + +<pre class="eval">document.writeln(<em>line</em>); +</pre> + +<h3 id="Parameters" name="Parameters">Parâmetros</h3> + +<ul> + <li><code>line</code> + + <div dir="ltr" style="zoom: 1;"><span class="short_text" id="result_box" lang="pt"><span class="hps">é uma string</span> <span class="hps">contendo</span> <span class="hps">uma linha de texto</span><span>.</span></span></div> + </li> +</ul> + +<h2 id="Example" name="Example">Exemplo</h2> + +<pre>document.writeln("<p>enter password:</p>"); +</pre> + +<h2 id="Notes" name="Notes">Notas</h2> + +<p><strong>document.writeln</strong> <span class="short_text" id="result_box" lang="pt"><span class="hps">é</span> <span class="hps">o mesmo que</span></span> <a href="/en/DOM/document.write" title="en/DOM/document.write">document.write</a> <span class="short_text" id="result_box" lang="pt"><span class="hps">mas acrescenta</span> <span class="hps">uma nova linha.</span></span></p> + +<div class="note"><strong>Note:</strong> <strong>document.writeln</strong> (like <strong>document.write</strong>) does not work in XHTML documents (you'll get a "Operation is not supported" (<code>NS_ERROR_DOM_NOT_SUPPORTED_ERR</code>) 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 <a class="external" href="http://www.w3.org/MarkUp/2004/xhtml-faq#docwrite" title="http://www.w3.org/MarkUp/2004/xhtml-faq#docwrite">W3C XHTML FAQ</a>.</div> + +<h2 id="Specification" name="Specification">Especificação</h2> + +<p><a class="external" href="http://www.w3.org/TR/2000/WD-DOM-Level-2-HTML-20001113/html.html#ID-35318390">writeln </a></p> |