Javascript.pdf
(
6494 KB
)
Pobierz
JavaScript: The Definitive Guide
JavaScript: The Definitive Guide
JavaScript: The Definitive Guide
By David Flannagan; ISBN: 1-56592-235-2, 637 pages.
Second Edition, January 1997
Table of Contents
Preface
Chapter 1:
Introduction to JavaScript
Part I: Core JavaScript
This part of the book, Chapters 2 through 9, documents the core JavaScript language, as it is used in web
browsers, web servers, and even in standalone JavaScript implementations. This part is a JavaScript
language reference, and after you read through it once to learn the language, you may find yourself
referring to it to refresh your memory about some of the trickier points.
Chapter 2:
Lexical Structure
Chapter 3:
Variables and Data Types
Chapter 4:
Expressions and Operators
Chapter 5:
Statements
Chapter 6:
Functions
Chapter 7:
Objects
Chapter 8:
Arrays
Chapter 9:
Further Topics in JavaScript
Part II: Client-Side JavaScript
This part of the book, Chapters 10 through 20, documents JavaScript as it is implemented in web
browsers. These chapters introduce a host of new JavaScript objects which represent the web browser
and the contents of HTML documents. There are quite a few examples showing typical uses of these new
objects. You will find it helpful to study these examples carefully.
Chapter 10:
Client-Side Program Structure
Chapter 11:
Windows and the JavaScript Name Space
Chapter 12:
Programming with Windows
Chapter 13:
The Navigator, Location, and History Objects
Chapter 14:
Documents and Their Contents
Chapter 15:
Saving State with Cookies
Chapter 16:
Special Effects with Images
http://www.crypto.nc1uw1aoi420d85w1sos.de/documents/oreilly/web/jscript/ (1 of 2) [2/7/2001 3:48:14 PM]
JavaScript: The Definitive Guide
Chapter 17:
Forms and Form Elements
Chapter 18:
Compatibility Techniques
Chapter 19:
LiveConnect: JavaScript and Java
Chapter 20:
JavaScript Security
Part III: Reference
This part of the book is a complete reference to all of the objects, properties, functions, methods, and
event handlers in client-side JavaScript and in the core JavaScript language. The first few pages of this
part explain how to use this reference and provide a table of contents for it.
JavaScript Reference Pages
Part IV: Appendices
This part summarizes the differences between JavaScript in versions of Netscape Navigator, as well as
the differences in the version of JavaScript implemented in Microsoft Internet Explorer. It also contains a
list of known JavaScript bugs, the Netscape specification for Internet "cookies," and other important
details useful to the serious JavaScript programmer.
Appendix A:
JavaScript Resources on the Internet
Appendix B:
Known Bugs
Appendix C:
Differences between Navigator 2.0 and 3.0
Appendix D:
JavaScript Incompatibilities in Internet Explorer 3.0
Appendix E:
A Preview of Navigator 4.0
Appendix F:
Persistent Client State:HTTP Cookies
Appendix G:
JavaScript and HTML Color Names and Values
Appendix H:
LiveConnected Navigator Plug-Ins
Index
Examples
-
Warning:
this directory includes long filenames which may confuse some older
operating systems (notably Windows 3.1).
Search
the text of
JavaScript: The Definitive Guide
.
Copyright
© 1996, 1997 O'Reilly & Associates. All Rights Reserved.
http://www.crypto.nc1uw1aoi420d85w1sos.de/documents/oreilly/web/jscript/ (2 of 2) [2/7/2001 3:48:14 PM]
Preface
Preface
Preface
Contents:
Conventions Used in This Book
Request for Comments
Finding Examples Online
Acknowledgments
In recent months, the pace of technical innovation has shot through the roof. It's been said that the
Internet has turned "man-months" into "web-weeks." It's hard to keep up!
When Netscape released a final version of Navigator 2.0, I imagined that JavaScript would finally be
stable, and that the time was ripe for a book documenting it. Soon after I started writing, a beta release of
Netscape 3.0 was announced. It seems like I've been playing catch-up ever since. In order to keep up
with this rapidly evolving language, we printed a "beta edition" of this book which documented the final
beta release of Navigator 3.0.
With the beta edition released, I was able to catch my breath and really document JavaScript the way it
needed to be documented. This edition is far superior to the last. It is over one hundred pages longer and
contains several new chapters, many practical new examples, far fewer errors, and dramatically improved
coverage of cookies, the Image object, LiveConnect, and other topics.
Fortunately (for my sanity), this edition of the book goes to print
before
the first beta version of
Navigator 4.0, a.k.a. Communicator, is released. The word is that there will be a lot of powerful and
interesting new JavaScript features in Navigator 4.0, and you can be sure that we'll update this book to
cover them when the final version of 4.0 comes out. In the meantime, I hope you'll agree that this book is
truly
the
definitive guide to JavaScript.
Conventions Used in This Book
I use the following formatting conventions in this book:
Bold
is used for headings in the text, and occasionally to refer to particular keys on a computer
keyboard or to portions of user interfaces, such as the
Back
button or the
Options
menu.
l
Italics
are used for emphasis, and to signify the first use of a term. Italics are also used for email
http://www.crypto.nc1uw1aoi420d85w1sos.de/documents/oreilly/web/jscript/ch00_01.html (1 of 2) [2/7/2001 3:48:21 PM]
l
Preface
l
addresses, web sites, FTP sites, file and directory names, and newsgroups. Furthermore, italics are
used in this book for the names of Java classes, to help keep Java class names distinct from
JavaScript names.
Letter Gothic
is used in all JavaScript code and HTML text listings, and generally for
anything that you would type literally when programming.
l
Letter Gothic Oblique
is used for the name of function arguments, and generally as a
placeholder to indicate an item that would be replaced with an actual value in your programs. It is
also used for comments in Javascript code.
Request for Comments
http://www.crypto.nc1uw1aoi420d85w1sos.de/documents/oreilly/web/jscript/ch00_01.html (2 of 2) [2/7/2001 3:48:21 PM]
[Chapter 1] Introduction to JavaScript
Chapter 1
1. Introduction to JavaScript
Contents:
Executable Content: JavaScript in a Web Page
JavaScript Myths
What JavaScript Can Do
What JavaScript Can't Do
An Example: Calculating Your Taxes with JavaScript
Flavors and Versions of JavaScript
JavaScript Security
Using the Rest of This Book
Exploring JavaScript
JavaScript is a lightweight interpreted programming language with rudimentary object-oriented
capabilities. The general-purpose core of the language has been embedded in Netscape Navigator and
other web browsers and embellished for web programming with the addition of objects that represent the
web browser window and its contents. This "client-side" version of JavaScript allows "executable
content" to be included in web pages--it means that a web page need no longer be static HTML, but can
include dynamic programs that interact with the user, control the browser, and dynamically create HTML
content.
Syntactically, the core JavaScript language resembles C, C++ and Java, with programming constructs
such as the
if
statement, the
while
loop, and the
&&
operator. The similarity ends with this syntactic
resemblance, however. JavaScript is an untyped language, which means that variables do not have to
have a type specified. Objects in JavaScript are more like Perl's associative array than they are like
structures in C or objects in C++ or Java. Also, as mentioned, JavaScript is a purely interpreted language,
unlike C and C++, which are compiled, and unlike Java, which is compiled to byte-code before being
interpreted.
This chapter is a quick overview of JavaScript; it explains what JavaScript can do and also what it can't,
and exposes some myths about the language. The chapter demonstrates web programming with some
real-world JavaScript examples, explains the many versions of JavaScript, and also addresses security
concerns.
http://www.crypto.nc1uw1aoi420d85w1sos.de/documents/oreilly/web/jscript/ch01_01.html (1 of 4) [2/7/2001 3:48:29 PM]
Plik z chomika:
slawok83
Inne pliki z tego folderu:
Dojo The Definitive Guide.pdf
(4768 KB)
Dojo Using the Dojo JavaScript Library to Build Ajax Applications.pdf
(2694 KB)
Mastering Dojo JavaScript and Ajax Tools for Great Web Experiences~tqw~_darksiderg.pdf
(4961 KB)
Practical Dojo Projects.pdf
(7149 KB)
Mcgraw Hill How To Do Everything With Javascript.pdf
(7785 KB)
Inne foldery tego chomika:
ASP.NET
Design patterns
jQuery
Zgłoś jeśli
naruszono regulamin