Chapter10.Using Dreamweaver Behaviors


Chapter 10. Using Dreamweaver Behaviors

IN THIS CHAPTER

  • An Introduction to Dreamweaver Behaviors

  • Using the Behaviors Panel

  • Dreamweaver Behaviors

As we've progressed through the book, we've touched on topics such as client-side web pages and server-side applications. In the previous chapter, we mentioned that HTML forms are the stepping stone for working with server-side applications but still remain an integral part of client-side web page development. What we haven't touched on, however, are the three building blocks that make up client-side web pages or the functionality and look with which the end user interacts. At the foundation of client-side development lies the first block, HTML/XHTML. Everything we do on the web, to a certain extent, revolves around HTML/XHTML. Dreamweaver, by definition, is a tool for creating HTML/XHTML pages for the web. The second building block, discussed in some detail in Chapter 7, "Advanced Page Formatting Using Style Sheets," is CSS. As we've seen, style sheets control the overall look and appearance of HTML/XHTML pages and again, are significantly supported by Dreamweaver. The third and final block to client-side web page development, JavaScript, has yet to be discussed.

At its heart, JavaScript exists as a web-based scripting language. While HTML/XHTML defines the structure of our client-side web pages and CSS controls the "look" of our web pages, JavaScript exists to outline the logic that our web pages will have in the form of a full-blown interactive scripting language similar in nature, but independent of, the object-oriented programming language Java. For instance, you may want to add functionality to your web page that otherwise wouldn't be available through HTML or CSSsuch as creating a pop-up message, a pop-up window, a pop-up menu, or even image-based rollovers for a navigation menu. Even better, you might want to add functionality to the helpdesk.htm page that guarantees that users enter text into all required fields, enter a number for their station ID, and even enter an email address into a text box that requires an email address. Furthermore, you might want to add functionality that forces the browser to check for a specific plug-in like Flash and have the browser react accordingly. All this and much more is possible with JavaScript.

As is true with HTML and CSS, you aren't required to know JavaScript when working in Dreamweaver. And as do HTML and CSS, Dreamweaver writes all the JavaScript to make these actions happen in the form of behaviors. Exposed as canned JavaScript snippets of code and available in the Behaviors panel, behaviors available in Dreamweaver are ideal for real-world applications where time is of the essence and your JavaScript writing skills are limited.

This chapter aims at preparing you to work with the final building block to client-side web development, JavaScript behaviors. To begin, you'll need to download the support files online. As you have done for the rest of the chapters in this book, you can work with the examples in this chapter by downloading the files from www.dreamweaverunleashed.com. You'll want to save the files for Chapter 10 in an easy-to-find location. I'll place mine in C:\Dorknozzle\Chapter10.




Macromedia Dreamweaver 8 Unleashed
Macromedia Dreamweaver 8 Unleashed
ISBN: 0672327600
EAN: 2147483647
Year: 2005
Pages: 237
Authors: Zak Ruvalcaba

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net