The Book of JavaScript, 2nd Edition

Jan. 16, 2007
By David Thau
ISBN: 1-59327-106-9

Scripting languages are becoming more important in embedded applications as the level of connectivity continues to rise. It is no longer sufficient to provide a Web interface to a remote device. Now a higher level of interaction is a requirement. This is why it is important for embedded developers to take a look at things like JavaScript and AJAX (Asynchronous JavaScript and XML).

The Book of JavaScript, 2nd Edition, by David Thau does not target embedded developers specifically, but it does provide the basics in a fashion that any embedded developer will appreciate. It covers JavaScript along with the more advanced AJAX. This book starts with the basics and provides practical examples that can be tried with most Web browsers and servers.

Moving computation and the user interface to a PC can offload small, microcontroller-based systems. Basic JavaScript can often suffice. Thau covers the language and browser compatibility right at the start. The first working example covers rollovers, events that occur when a mouse cursor is placed over a field or element in the Web browser's screen. The material then moves on to window manipulation.

The author's presentation methodology uses small text snippets of code where important lines are numbered. These highlights are matched with explanation in the text. It works very well as long as the figure is on the same page as the explanation; otherwise, page flipping results. Luckily, this does not happen often. The approach also eliminates cryptic comments in the sample code and provides a more detailed discussion when necessary.

The book covers all of the important details like cookie handling and dynamic HTML, and it then gets into AJAX basics. The latter is covered in two chapters along with a server-side discussion. This provides sufficient information to see how AJAX works, but you will still want to get an AJAX book to get into more sophisticated applications. Given the number of different AJAX development tools and platforms, this level of presentation works best because anything else would be very specific to one of these tools and platforms.

The book includes assignments with each chapter, making it suitable for class work. It also has the answers in the appendices.

If you want to get your feet wet with JavaScript and AJAX, then this is the book for you. A little background in almost any other programming language helps, but you will be able to handle the basics after getting through this book even if you are starting from ground zero.

Sponsored Recommendations

Near- and Far-Field Measurements

April 16, 2024
In this comprehensive application note, we delve into the methods of measuring the transmission (or reception) pattern, a key determinant of antenna gain, using a vector network...

DigiKey Factory Tomorrow Season 3: Sustainable Manufacturing

April 16, 2024
Industry 4.0 is helping manufacturers develop and integrate technologies such as AI, edge computing and connectivity for the factories of tomorrow. Learn more at DigiKey today...

Connectivity – The Backbone of Sustainable Automation

April 16, 2024
Advanced interfaces for signals, data, and electrical power are essential. They help save resources and costs when networking production equipment.

Empowered by Cutting-Edge Automation Technology: The Sustainable Journey

April 16, 2024
Advanced automation is key to efficient production and is a powerful tool for optimizing infrastructure and processes in terms of sustainability.

Comments

To join the conversation, and become an exclusive member of Electronic Design, create an account today!