Programming Books C Java PHP Python Learn more Browse Programming Books

Sorry, this item is not available in
Image not available for
Image not available

To view this video download Flash Player

FREE Shipping on orders over $35.

Used - Like New | See details
Have one to sell? Sell yours here
Tell the Publisher!
I'd like to read this book on Kindle

Don't have a Kindle? Get your Kindle here, or download a FREE Kindle Reading App.

JavaScript: The Definitive Guide [Paperback]

by David Flanagan
4.3 out of 5 stars  See all reviews (60 customer reviews)

Available from these sellers.

Free Two-Day Shipping for College Students with Amazon Student


Amazon Price New from Used from
Hardcover --  
Paperback --  
Shop the new
New! Introducing the, a hub for Software Developers and Architects, Networking Administrators, TPMs, and other technology professionals to find highly-rated and highly-relevant career resources. Shop books on programming and big data, or read this week's blog posts by authors and thought-leaders in the tech industry. > Shop now
There is a newer edition of this item:
JavaScript: The Definitive Guide: Activate Your Web Pages (Definitive Guides) JavaScript: The Definitive Guide: Activate Your Web Pages (Definitive Guides) 4.4 out of 5 stars (96)
In Stock.

Book Description

December 15, 2001 0596000480 978-0596000486 Fourth Edition

JavaScript is a powerful, object-based scripting language; JavaScript programs can be embedded directly in HTML web pages. When combined with the Document Object Model (DOM) defined by a web browser, JavaScript allows you to create Dynamic HTML content and interactive client-side web applications. JavaScript syntax is based on the popular programming languages C, C++, and Java, which makes it familiar and easy to learn for experienced programmers. At the same time, JavaScript is an interpreted scripting language, providing a flexible, forgiving programming environment in which new programmers can learn.

JavaScript: The Definitive Guide provides a thorough description of the core JavaScript language and both the legacy and standard DOMs implemented in web browsers. The book includes sophisticated examples that show you how to handle common tasks, like validating form data, working with cookies, and creating portable DHTML animations. The book also contains detailed reference sections that cover the core JavaScript API, the legacy client-side API, and the W3C standard DOM API, documenting every JavaScript object, method, property, constructor, constant, function, and event handler in those APIs.

This fourth edition of the bestselling JavaScript book has been carefully updated to cover JavaScript 1.5 (ECMAScript version 3). The book also provides complete coverage of the W3C DOM standard (Level 1 and Level 2), while retaining material on the legacy Level 0 DOM for backward compatibility.

JavaScript: The Definitive Guide is a complete programmer's guide and reference manual for JavaScript. It is particularly useful for developers working with the latest standards-compliant web browsers, like Internet Explorer 6, Netscape 6, and Mozilla. HTML authors can learn how to use JavaScript to build dynamic web pages. Experienced programmers can quickly find the information they need to start writing sophisticated JavaScript programs. This book is an indispensable reference for all JavaScript programmers, regardless of experience level.

Editorial Reviews Review

Since the earliest days of Internet scripting, Web developers have considered JavaScript: The Definitive Guide an essential resource. David Flanagan's approach, which combines tutorials and examples with easy-to-use syntax guides and object references, suits the typical programmer's requirements nicely. The brand-new fourth edition of Flanagan's "Rhino Book" includes coverage of JavaScript 1.5, JScript 5.5, ECMAScript 3, and the Document Object Model (DOM) Level 2 standard from the World Wide Web Consortium (W3C). Interestingly, the author has shifted away from specifying--as he did in earlier editions--what browsers support each bit of the language. Rather than say Netscape 3.0 supports the Image object while Internet Explorer 3.0 does not, he specifies that JavaScript 1.1 and JScript 3.0 support Image. More usefully, he specifies the contents of independent standards like ECMAScript, which encourages scripters to write applications for these standards and browser vendors to support them. As Flanagan says, JavaScript and its related subjects are very complex in their pure forms. It's impossible to keep track of the differences among half a dozen vendors' generally similar implementations. Nonetheless, a lot of examples make reference to specific browsers' capabilities.

Though he does not cover server-side APIs, Flanagan has chosen to separate coverage of core JavaScript (all the keywords, general syntax, and utility objects like Array) from coverage of client-side JavaScript (which includes objects, like History and Event, that have to do with Web browsers and users' interactions with them. This approach makes this book useful to people using JavaScript for applications other than Web pages. By the way, the other classic JavaScript text--Danny Goodman's JavaScript Bible--isn't as current as this book, but it's still a fantastic (and perhaps somewhat more novice-friendly) guide to the JavaScript language and its capabilities. --David Wall

Topics covered: The JavaScript language (version 1.0 through version 1.5) and its relatives, JScript and ECMAScript, as well as the W3C DOM standards they're often used to manipulate. Tutorial sections show how to program in JavaScript, while reference sections summarize syntax and options while providing copious code examples.


"JavaScript is not a cookbook, although plenty of example code is include; nor is it an introduction for beginners, although every aspect of JavaScript is covered from the ground up. It is - what it sets out to be - definitive reference guide for the JavaScript programmer." - Richard Drummond, LinuxFormat, June 2002

Product Details

  • Series: Definitive Guides
  • Paperback: 900 pages
  • Publisher: O'Reilly Media; Fourth Edition edition (December 15, 2001)
  • Language: English
  • ISBN-10: 0596000480
  • ISBN-13: 978-0596000486
  • Product Dimensions: 9.1 x 7 x 1.7 inches
  • Shipping Weight: 2.8 pounds
  • Average Customer Review: 4.3 out of 5 stars  See all reviews (60 customer reviews)
  • Amazon Best Sellers Rank: #750,606 in Books (See Top 100 in Books)

More About the Author

David Flanagan is a computer programmer who has spent much of the last 20 years writing books about programming languages. He now works at Mozilla. David lives with his wife and children in the Pacific Northwest, between the cities of Seattle and Vancouver.

Customer Reviews

Most Helpful Customer Reviews
21 of 21 people found the following review helpful
5.0 out of 5 stars Another great one from Flanagan September 10, 2004
If you're already an experienced programmer, it can be frustrating trying to find a good book on JavaScript (aka JScript, aka ECMAScript, aka ECMA-262). A lot of books out there are aimed at HTML developers, maybe even graphic designers. Many such users have little or no real programming experience, and maybe no real interest. Books for that audience are user-friendly, filled with useful examples, and low on scary-sounding technical terms. In other words, almost useless.

Flanagan has good credentials as a technical writer, and as a highly technical writer. He really knows what software engineers look for - trust me, it's not what a graphic designer looks for.

This starts with a clear, methodical description of the language. Flanagan goes through all the language basics, pointing out where JavaScript differs form languages like Java, C#, or C++. The differences are numerous. For example, JavaScript has typed data, but not typed variables. It's object oriented, but doesn't have classes. It's an interpreted language, not compiled, and that opens up generative programming possibilities that reflection APIs can't approach.

After the language itself, Flanagan presents it in the client-side HTML context, where it appears most often. That's about 20% of the book. It goes over all the common HTML features, and shows how JavaScript can add dynamics or configurability to most HTML features. The last part of this section discusses XML and the DOM model. It does not yet discuss the E4X standard, ECMAScript for XML, the new ECMA-357 standard. As of this writing, the standard has only been out for three months, though. I'm sure Flanagan will catch up to it soon.
Read more ›
Comment | 
Was this review helpful to you?
18 of 18 people found the following review helpful
4.0 out of 5 stars Buy V4, but don't throw away V3. January 8, 2002
Having recently shipped an open source JavaScript application framework comprising 125,000 lines of JavaScript (TIBET) I can say it would have been impossible without Version 3 of this book -- and impossible with only Version 4 of this book.
Where Version 3 focused on documenting the *reality* of the browsers, covering the various bugs and inconsistencies in detail, Version 4 abandons that approach in favor of documenting the *dream* embodied in the standards. While that's "a good thing", what's really needed, and what was provided by Version 3, is a volume that also covers how the browers vary from the standards. That's what made V3 the best JavaScript book on the market. Much of that content has been removed from V4 however.
V4 is a solid effort. Don't get me wrong. You should have a copy. The coverage is for the most part accurate and accessible. The new content on Mozilla and the DOM/CSS standards is solid. But the missing material means you can't toss all your other JS books and just settle down with JSTDG V4 :(.
With V3 you rarely needed to go anywhere else. With V4 I find myself looking back at V3 to check accuracy or going to the net to search for bug reports. The book just isn't as functional in the real world of web development. So buy V4, but don't get rid of that well-used copy of V3 just yet ;).
Comment | 
Was this review helpful to you?
33 of 37 people found the following review helpful
4.0 out of 5 stars Good book but 4th edition starting to become out-dated February 21, 2006
I have had this book for years. I really like this book a lot.

It teaches you the language. It is a good reference for the syntax of Javascript 1.5. It also does a decent job of teaching DHTML. Some foreknowledge of HTML is going to be helpful. That can easily be gained from other books, reading the spec, or going through some of the HTML tutorials on the web. This book tells you how to access the structure of an HTML document - and change it.

Amazingly, it really did not start to become obsolete for almost half a decade. For a computer book on a heavily used computer language, that is great.

In late 2005, Mozilla released Firefox 1.5 which included a new version of Javascript: Javascript 1.6. Unlike some updates, this one was a doozy.

Javascript 1.6 introduced a feature called E4X - Ecmascript for Java. This powerful feature actually upgrades the language, making XML fragments a first class data type.

What this means is two things:

First, you can put XML fragments in your program. Just as quoted strings are interpreted as string literals, these fragments are treated as XML literals. No quoting or anything is required: the parser just sees them and knows what they are.

Second, you can evaluate XPath-like expressions to find things in an XML fragment value. Those things would be attribute values, text content, and elements that are in it.

Today, XML is much more important to organizations and much more useful to programmers than it was in 2001. It is a given that easier, more powerful ways for programmers to work with XML are going to grab programmers' interest.

Another thing has changed since 2001. AJAX programming has become white-hot.
Read more ›
Comment | 
Was this review helpful to you?
23 of 25 people found the following review helpful
5.0 out of 5 stars Worth its weight in gold February 26, 2002
I own the third edition of this book, and bought it when I was starting to write a web-based decision support system for a very large beverage company. I can safely say that this book, and the HTML Definitive Guide (also by O'Reilly) were critical to the success of the system.
I have seldom had a question about JavaScript for which I could not find the answer in this book. I referred to it so frequently during the development of our system that it is now the most dog-eared book in my collection. I'm going to order the fourth edition simply because this baby is ready for retirement.
If you are learning client-side JavaScript, by all means purchase this book. The first half of the book is a guided introduction to the language and does a wonderful job of explaining the syntax of the language, the underlying object model, and virtually every pertinent feature of the language. The real value, though, is in the reference, which documents every object, method, property and event of standard JavaScript.
Non-conformists who wish to exploit features unique to Internet Explorer will find some reference material here, but the book does try to focus on the "standard" features of the language, which I think is a good thing.
You just can't go wrong with this book.
Comment | 
Was this review helpful to you?
Most Recent Customer Reviews
5.0 out of 5 stars Amazing book
This is a must have book for a javascript developer of every skill level. This book will help you grasp many core concepts that are the common stumbling blocks for most javascript... Read more
Published 6 months ago by Vladimir
1.0 out of 5 stars Obsolete!
JavaScript developing has changed so much that this book is just no longer useful. The current edition is an excellent work, but programming in JavaScript has changed a lot since... Read more
Published 13 months ago by dannyboy
5.0 out of 5 stars Monster
I used through chapter 12, after that I was all set for what I needed. If you are going to commit teh entiure thing with self study, good luck! LOL
Published 15 months ago by Ed Canupp
5.0 out of 5 stars Great Taste of Javascript
JavaScript: The Definitive Guide by David Flanagan is probably the best reference possible for this extremely useful, but complex language. Read more
Published on February 3, 2009 by Andrei Mouravski
5.0 out of 5 stars Javascript All in one Book.
If you want to master Javascript and read just one book, then this must be the book you want to buy. Covers A-Z, detailed. Read more
Published on May 6, 2008 by Shanmuga Sundaram D
4.0 out of 5 stars Extensive reference on Javascript
O'Reilly books are always of high quality. At over 900 pages this book is a very complete reference. It has the functional organization characteristic of reference books. Read more
Published on September 28, 2007 by George Fragos
5.0 out of 5 stars The Granddaddy of Them All
This book truly is the grand daddy of them all! The depth of Javascript resources is immense. I cannot even begin to think of the number of times this book has saved my bacon... Read more
Published on August 29, 2006 by Donald Bickel
5.0 out of 5 stars A programmer's JavaScript reference
If you've been in web programming for a while, you're undoubtedly familiar with JavaScript, but may have dismissed it as a "toy language" for flashy graphics effects without much... Read more
Published on May 12, 2006 by Joshua Davies
5.0 out of 5 stars Better than a reference
JavaScript the definitive guide is not only the reference, it is built following a logical pattern, is full of useful tips, warnings and recommendations ; it is made by somebody... Read more
Published on May 11, 2006 by Quasimodal
1.0 out of 5 stars Way out-dated; new edition coming out Aug 2006
This 4th edition of Javascript was published in 2001 and is by now way out-dated. Granted, a lot has *not* changed with Javascript, but new techniques and formats have become... Read more
Published on May 8, 2006 by Gadgester
Search Customer Reviews
Only search this product's reviews

What Other Items Do Customers Buy After Viewing This Item?

Sell a Digital Version of This Book in the Kindle Store

If you are a publisher or author and hold the digital rights to a book, you can sell a digital version of it in our Kindle Store. Learn more


Search Customer Discussions
Search all Amazon discussions

Topic From this Discussion
Absolutely positively not. It would be a terrible mistake and really hurt your energy and enthusiasm.

There is a very good "Javascript for Beginners" that gets reasonably deep and is plenty hard enough for a total beginner.

That said, when a new edition of this comes out, it might be... Read more
Feb 15, 2010 by R. M. Barge |  See all 2 posts
5th Ed. is FOUR years out of date... any word of a SIXTH edition coming...
The answer to your first question is

As to your second question, I was wondering the same thing.
Apr 13, 2010 by Neurosion |  See all 4 posts
How is this on the kindle? Be the first to reply
Which edition is the digital download? Be the first to reply
Is 5th Edition *MUCH* different from the 3rd edition? Be the first to reply
Start a new discussion
First post:
Prompts for sign-in

Look for Similar Items by Category