JavaScript Application Cookbook

May 1st, 2000 by Ralph Krause in

A good resource for anyone who wants to take advantage of the power of JavaScript.
Your rating: None
  • Author: Jerry Bradenbaugh

  • Publisher: O'Reilly & Associates

  • E-mail: info@oreilly.com

  • URL: http://www.ora.com/

  • Price: $34.95 US

  • ISBN: 1-56592-577-7

  • Reviewer: Ralph Krause

The JavaScript Application Cookbook written by Jerry Bradenbaugh and published by O'Reilly is a good resource for anyone who wants to take advantage of the power of JavaScript. Instead of providing a language tutorial or a collection of routines, the book contains fully functional JavaScript applications. Some of the applications included are a client-side search engine, a shopping cart, a context-sensitive help system, and a drag-and-drop application that lets users build their own DHTML e-mail greeting cards. The applications are fully functional and show how powerful JavaScript can be.

The application source code and images are available from O'Reilly's web site as one big Zip file. The book does contain the source code listings, but since some of them contain over 400 lines, I suggest downloading the file instead of trying to type the code from the book. While the code is not heavily commented, Mr. Bradenbaugh thoroughly explains it in the body of the book.

I downloaded the source code and ran all of the applications first on my home computer and then over the Web from my home page. All the applications run quickly within a browser and most of them load fairly quickly, even over a dial-up connection.

The book is made up of eleven chapters, each (except for one) containing one application. The chapter that does not include an application contains JavaScript routines that can be added to your existing code. Quite a few of the routines presented in this chapter are used in the other applications in the book.

All the chapters are laid out in the same way. The application features and JavaScript techniques used are stated at the beginning of the chapter, along with an overview of the application and any special browser requirements. Screen shots of the running application are also provided.

Next comes a syntax breakdown which contains a source code listing, followed by an explanation of how each section of the code works. These breakdowns are not JavaScript tutorials; instead, they show how the code interacts with the browser and explain some of the more powerful and exotic JavaScript features used by the application. Mr. Bradenbaugh's explanations are clear and concise, and he includes quite a few sidebars and web addresses for more information on complex subjects.

Each chapter ends with a section called Potential Extensions. These sections provide thoughts on how the reader can extend and modify the application that was just presented. While some code snippets are provided, the majority of the work is left to the reader to accomplish.

The book contains three appendices. The first is a JavaScript reference. The second appendix provides links to JavaScript- and web-related resources, as well as sites with applications similar to the ones presented in the book. The third appendix contains a Perl/CGI overview.

Mr. Bradenbaugh provides quite a bit of explanation and code showing how to have your code determine if it is running on a Netscape or a Microsoft browser, then run correctly when doing such things as DHTML. I tried running some of the applications on both Netscape and Microsoft browsers, and they worked correctly each time.

The book's applications demonstrate good attention to detail. Such things as positioning buttons correctly when creating a page, positioning new browser windows so that they don't completely cover existing windows, and putting search results in alphabetical order are hallmarks of polished applications.

I did not find any errors in the book, and there were no errata on O'Reilly's web site when I looked. The only thing that was not correct as stated in the book are the web addresses for Internet Explorer information. These pages were moved by Microsoft when they redesigned their site.

I found the JavaScript Application Cookbook to be a useful book, containing applications that can be used right away. The explanations and code breakdown do a very good job of illustrating the power of JavaScript. While not a JavaScript primer, the book will be useful for someone with JavaScript experience who wants to create powerful programs.

Ralph Krause is a freelance computer consultant in Michigan. His current career goal is to stay out of automotive paint shops. He can be reached via e-mail at rkrause@netperson.net.

__________________________


Special Magazine Offer -- Free Gift with Subscription
Receive a free digital copy of Linux Journal's System Administration Special Edition as well as instant online access to current and past issues. CLICK HERE for offer

Linux Journal: delivering readers the advice and inspiration they need to get the most out of their Linux systems since 1994.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
enigma sadness mp3 download's picture

linux

On October 2nd, 2007 enigma sadness mp3 download (not verified) says:

How can I mode? scrollback get in text Thanks.

Post new comment

Please note that comments may not appear immediately, so there is no need to repost your comment.
The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <pre> <ul> <ol> <li> <dl> <dt> <dd> <i> <b>
  • Lines and paragraphs break automatically.

More information about formatting options

Newsletter

Each week Linux Journal editors will tell you what's hot in the world of Linux. You will receive late breaking news, technical tips and tricks, and links to in-depth stories featured on www.linuxjournal.com.
Sign up for our Email Newsletter

Featured Videos

Setting up an https server in Apache is easy. This tutorial covers how to create and sign your ssl certificate as well as how to configure the web server.

From the Magazine

January 2009, #177

It's a battle as old as time: good vs. evil. Fortunately, Linux and FOSS are on our side as we wage the battle against those who try to steal our secrets and invade our systems.

Checking your system's security is best done sooner rather than later. Test the locks with our article on security verification; find out how to use PAM to help secure your systems; use MinorFS and AppArmor to implement discretionary access control; learn more about Samba security in part III of our series; use Darknet to help detect bots and secure your systems; use the Yubikey to increase your site's security; and don't forget to lock the doors, because a cold boot attack could render your security useless if somebody has physical access to your computer.

But, we're not just about sowing the seeds of fear. We also show you how to use memcached in Rails, how to manage multiple servers efficiently, how to deploy applications easily with Capistrano, how to manage your videos with MythVideo, how to mix it up a bit (your audio that is), and even play a few games.

Read this issue