mozilla

Revision 363191 of About this Guide

  • Revision slug: JavaScript/Guide/About
  • Revision title: Sobre este Guia
  • Revision id: 363191
  • Created:
  • Creator: regisdiogo
  • Is current revision? No
  • Comment

Revision Content

JavaScript é uma linguagem de programação de script multiplataforma e orientada a objetos. Este guia explica tudo que você precisa saber sobre usar JavaScript.

Novos recursos nas versões do JavaScript

{{ JSGVersions() }}

O que você já deveria saber

Este guia assume que você tem o seguinte conhecimento básico:

  • Um entendimento geral da Internet e da World Wide Web (WWW).
  • Bom conhecimento de HyperText Markup Language (HTML).
  • Alguma experiência com programação. Se você é um novato em programação, use um dos tutoriais listados na página JavaScript

Versões do JavaScript

Tabela 1 Versões do JavaScript e Navegadores
Versões do JavaScript Versão do Navegador
JavaScript 1.0 Navigator 2.0
JavaScript 1.1 Navigator 3.0
JavaScript 1.2 Navigator 4.0-4.05
JavaScript 1.3 Navigator 4.06-4.7x
JavaScript 1.4  
JavaScript 1.5 Navigator 6.0
Mozilla (open source browser)
JavaScript 1.6 Firefox 1.5, other Mozilla 1.8-based products
JavaScript 1.7 Firefox 2, other Mozilla 1.8.1-based products
JavaScript 1.8 Firefox 3, other Gecko 1.9-based products

Cada versão do Netscape Enterprise Server também suporta uma versão diferente do JavaScript. Para te ajudar a escrever scripts que são compatíveis com múltiplas versões do Enterprise Server, este manual usa uma abreviação para indicar o servidor em qual cada recurso foi implementado.

Table 2 Abreviações das versões do Netscape Enterprise Server
Abreviação Versão Enterprise Server
NES 2.0 Netscape Enterprise Server 2.0
NES 3.0 Netscape Enterprise Server 3.0

Where to find JavaScript information

JavaScript documentation includes the following books:

If you are new to JavaScript, start with the JavaScript Guide. Once you have a firm grasp of the fundamentals, you can use the JavaScript Reference to get more details on individual objects and statements.

Tips for learning JavaScript

Getting started with JavaScript is easy: all you need is a modern Web browser. This guide includes some JavaScript features which are only currently available in the latest versions of Firefox (and other Gecko powered browsers), so using the most recent version of Firefox is recommended.

An interactive interpreter

An interactive JavaScript prompt is an invaluable aid to learning the language, as it enables you to try things out interactively without having to save a file and refresh a page. The Firefox Error Console, accessible through the Tools menu, provides a simple way to try interactive JavaScript: Just enter a line of code and click the "Evaluate" button.

Image:ErrorConsole.png

Firebug

A more advanced interactive prompt is available using Firebug, a Firefox extension. Expressions you type are interpreted as objects and linked to other parts of Firebug. For example, you can add 5 plus 5, change the case of a string, get a clickable link to the document, or get a link to an element:

Using the arrow on the right bottom corner gives a command editor for multiline scripts.

Firebug also provides an advanced DOM inspector, a JavaScript debugger, a profiling tool and various other utilities. JavaScript code running in a Web page can call, console.log(), a function that prints its arguments to the Firebug console.

Document conventions

JavaScript applications run on many operating systems; the information in this book applies to all versions. File and directory paths are given in Windows format (with backslashes separating directory names). For Unix versions, the directory paths are the same, except that you use slashes instead of backslashes to separate directories.

This guide uses uniform resource locators (URLs) of the following form:

http://server.domain/path/file.html

In these URLs, server represents the name of the server on which you run your application, such as research1 or www; domain represents your Internet domain name, such as netscape.com or uiuc.edu; path represents the directory structure on the server; and file.html represents an individual file name. In general, items in italics in URLs are placeholders and items in normal monospace font are literals. If your server has Secure Sockets Layer (SSL) enabled, you would use https instead of http in the URL.

This guide uses the following font conventions:

  • The monospace font is used for sample code and code listings, API and language elements (such as method names and property names), file names, path names, directory names, HTML tags, and any text that must be typed on the screen. (Monospace italic font is used for placeholders embedded in code.)
  • Italic type is used for book titles, emphasis, variables and placeholders, and words used in the literal sense.
  • Boldface type is used for glossary terms.
{{ autoPreviousNext("JSGChapters") }}

Revision Source

<p>JavaScript é uma linguagem de programação de script multiplataforma e orientada a objetos. Este guia explica tudo que você precisa saber sobre usar JavaScript.</p>
<h2 id="New_features_in_JavaScript_versions">Novos recursos nas versões do JavaScript</h2>
<p>{{ JSGVersions() }}</p>
<h2 id="What_you_should_already_know">O que você já deveria saber</h2>
<p>Este guia assume que você tem o seguinte conhecimento básico:</p>
<ul>
  <li>Um entendimento geral da Internet e da World Wide Web (WWW).</li>
  <li>Bom conhecimento de HyperText Markup Language (<a href="/en/HTML" title="en/HTML">HTML</a>).</li>
  <li>Alguma experiência com programação. Se você é um novato em programação, use um dos tutoriais listados na página <a href="/en-US/docs/JavaScript" title="/en-US/docs/">JavaScript</a></li>
</ul>
<h2 id="JavaScript_versions">Versões do JavaScript</h2>
<table class="standard-table">
  <caption style="text-align: left;">
    Tabela 1 Versões do JavaScript e Navegadores</caption>
  <thead>
    <tr>
      <th scope="col">Versões do JavaScript</th>
      <th scope="col">Versão do Navegador</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>JavaScript 1.0</td>
      <td>Navigator 2.0</td>
    </tr>
    <tr>
      <td>JavaScript 1.1</td>
      <td>Navigator 3.0</td>
    </tr>
    <tr>
      <td>JavaScript 1.2</td>
      <td>Navigator 4.0-4.05</td>
    </tr>
    <tr>
      <td>JavaScript 1.3</td>
      <td>Navigator 4.06-4.7x</td>
    </tr>
    <tr>
      <td>JavaScript 1.4</td>
      <td>&nbsp;</td>
    </tr>
    <tr>
      <td>JavaScript 1.5</td>
      <td>Navigator 6.0<br />
        Mozilla (open source browser)</td>
    </tr>
    <tr>
      <td>JavaScript 1.6</td>
      <td><a href="/en/Firefox_1.5_for_developers" title="en/Firefox_1.5_for_developers">Firefox 1.5</a>, other Mozilla 1.8-based products</td>
    </tr>
    <tr>
      <td>JavaScript 1.7</td>
      <td><a href="/en/Firefox_2_for_developers" title="en/Firefox_2_for_developers">Firefox 2</a>, other Mozilla 1.8.1-based products</td>
    </tr>
    <tr>
      <td>JavaScript 1.8</td>
      <td><a href="/en/Firefox_3_for_developers" title="en/Firefox_3_for_developers">Firefox 3</a>, other Gecko 1.9-based products</td>
    </tr>
  </tbody>
</table>
<p>Cada versão do Netscape Enterprise Server também suporta uma versão diferente do JavaScript. Para te ajudar a escrever scripts que são compatíveis com múltiplas versões do Enterprise Server, este manual usa uma abreviação para indicar o servidor em qual cada recurso foi implementado.</p>
<table class="standard-table" height="90" width="491">
  <caption style="text-align: left;">
    Table 2 Abreviações das versões do Netscape Enterprise Server</caption>
  <thead>
    <tr>
      <th scope="col">Abreviação</th>
      <th scope="col">Versão Enterprise Server</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>NES 2.0</td>
      <td>Netscape Enterprise Server 2.0</td>
    </tr>
    <tr>
      <td>NES 3.0</td>
      <td>Netscape Enterprise Server 3.0</td>
    </tr>
  </tbody>
</table>
<h2 id="Where_to_find_JavaScript_information">Where to find JavaScript information</h2>
<p>JavaScript documentation includes the following books:</p>
<ul>
  <li><a href="/en/JavaScript/Guide" title="en/Core_JavaScript_1.5_Guide">JavaScript Guide</a> (this guide) provides information about JavaScript language and its objects.</li>
  <li><a href="/en/JavaScript/Reference" title="en/JavaScript/Reference">JavaScript Reference</a> provides reference material for JavaScript language.</li>
</ul>
<p>If you are new to JavaScript, start with the <a href="/en/JavaScript/Guide" title="en/Core_JavaScript_1.5_Guide">JavaScript Guide</a>. Once you have a firm grasp of the fundamentals, you can use the <a href="/en/JavaScript/Reference" title="en/JavaScript/Reference">JavaScript Reference</a> to get more details on individual objects and statements.</p>
<h2 id="Tips_for_learning_JavaScript">Tips for learning JavaScript</h2>
<p>Getting started with JavaScript is easy: all you need is a modern Web browser. This guide includes some JavaScript features which are only currently available in the latest versions of Firefox (and other Gecko powered browsers), so using the most recent version of Firefox is recommended.</p>
<h3 id="An_interactive_interpreter">An interactive interpreter</h3>
<p>An interactive JavaScript prompt is an invaluable aid to learning the language, as it enables you to try things out interactively without having to save a file and refresh a page. The Firefox Error Console, accessible through the Tools menu, provides a simple way to try interactive JavaScript: Just enter a line of code and click the "Evaluate" button.</p>
<p><img alt="Image:ErrorConsole.png" class="internal" src="/@api/deki/files/192/=ErrorConsole.png" /></p>
<h3 id="Firebug">Firebug</h3>
<p>A more advanced interactive prompt is available using <a class="external" href="http://www.getfirebug.com/">Firebug</a>, a Firefox extension. Expressions you type are interpreted as objects and linked to other parts of Firebug. For example, you can add 5 plus 5, change the case of a string, get a clickable link to the document, or get a link to an element:</p>
<p><img alt="" class="internal" src="/@api/deki/files/5188/=FirebugCommandLine.PNG" style="width: 728px; height: 281px;" /></p>
<p>Using the arrow on the right bottom corner gives a command editor for multiline scripts.</p>
<p>Firebug also provides an advanced DOM inspector, a JavaScript debugger, a profiling tool and various other utilities. JavaScript code running in a Web page can call, <code>console.log()</code>, a function that prints its arguments to the Firebug console.</p>
<h2 id="Document_conventions">Document conventions</h2>
<p>JavaScript applications run on many operating systems; the information in this book applies to all versions. File and directory paths are given in Windows format (with backslashes separating directory names). For Unix versions, the directory paths are the same, except that you use slashes instead of backslashes to separate directories.</p>
<p>This guide uses uniform resource locators (URLs) of the following form:</p>
<p><code>http://<em>server</em>.<em>domain</em>/<em>path</em>/<em>file</em>.html</code></p>
<p>In these URLs, <em>server</em> represents the name of the server on which you run your application, such as <code>research1</code> or <code>www</code>; <em>domain</em> represents your Internet domain name, such as <code>netscape.com</code> or <code>uiuc.edu</code>; <em>path</em> represents the directory structure on the server; and <em>file</em><code>.html</code> represents an individual file name. In general, items in italics in URLs are placeholders and items in normal monospace font are literals. If your server has Secure Sockets Layer (SSL) enabled, you would use <code>https</code> instead of <code>http</code> in the URL.</p>
<p>This guide uses the following font conventions:</p>
<ul>
  <li><code>The monospace font</code> is used for sample code and code listings, API and language elements (such as method names and property names), file names, path names, directory names, HTML tags, and any text that must be typed on the screen. (<code><em>Monospace italic font</em></code> is used for placeholders embedded in code.)</li>
  <li><em>Italic type</em> is used for book titles, emphasis, variables and placeholders, and words used in the literal sense.</li>
  <li><strong>Boldface</strong> type is used for glossary terms.</li>
</ul>
<div>
  {{ autoPreviousNext("JSGChapters") }}</div>
Revert to this revision