Many web designers rely on WYSIWYG tools and editors for creating web pages. These tools make it possible to see the effects of creating and editing immediately. There are a number of DHTML WYSIWYG editors available today that may suit your needs for creating dynamic web pages.
Even with the relatively simple examples we've examined in this chapter, you can see that hand coding DHTML can be complicated and arduous. In addition, the differences between Navigator 4.0 and Internet Explorer 4.0 force web designers to write two additional sets of code for each function, to retain backwards-compatibility. This increases production time and creates code that is difficult to read and maintain.
There are many tools that create DHTML for you behind the scenes. Some of these tools are narrow in focus and provide specific functionality, while others, such as Macromedia Dreamweaver and Adobe GoLive, are full packages with which you can create and maintain whole web sites, as well as write DHTML code.
It is beyond the scope of this book to provide working details of WYSIWIG DHTML tools. Each of these tools has their own pros and cons. Commercial tools with full DHTML support are likely to provide a more robust implementation and better support to users. However, these software packages require a larger investment of time and money. If you want only simple animations or style changes, a shareware tool may be the best way for you to go. Luckily, most web authoring tools are available for free download over the Internet on a trial basis, so you can experiment and choose the one that suits your needs. To learn about available tools, check out the resources listed at the end of this chapter.
WYSIWYG DHTML tools differ greatly in their operation. They have to allow you to view and manipulate layers, styles, scripts, and animation in a graphical way. You can create animations by dragging objects in the editor, thus eliminating the need to write JavaScript that counts pixels and tracks x,y coordinates. Dreamweaver, for instance, features built-in behaviors for rollovers, moving layers, and changing styles. You can also download extensions from Macromedia's web site, most of them created by third-party developers; these add a variety of DHTML behaviors and commands to Dreamweaver.
Consider these advantages to using WYSIWYG DHTML tools:
There is a shorter learning curve for WYSIWYG editors. Because DHTML is a combination of HTML, JavaScript, Cascading Style Sheets, and DOM, it has a steep learning curve. An editor hides the complexities of DHTML and allows you to manipulate objects through a timeline or other graphic interface.
Editors allow you to create effects more quickly. An effect that could take hours of coding and then debugging may be created on a WYSIWYG editor in a matter of minutes.
Cross-browser implementation is less of a worry. Browser compatibility is less of an issue with DHTML editors. Most of them create cross-browser DHTML, and most will also tell you which behaviors will work with which browsers.
There are also some disadvantages, however:
WYSIWYG editors are expensive. Some of these editors can cost hundreds of dollars, which isn't within every developer's budget. Editors can vary greatly in price, so shop around. Luckily, most software companies allow you to try their editor for free so that you can make an educated decision before buying.
Editors may not give precise control over your objects. Not every editor gives you pixel level control over your dynamic objects and pages. Many designs require precise, pixel-level control of dynamic objects. Also, you are viewing your code as your editor chooses to depict it -- if bugs do occur in your DHTML pages, they may be more difficult to fix.
An editor may not do everything. By using a WYSIWYG editor, you are removing yourself from your DHTML code by one degree. If you are dependent upon your editor for DHTML effects, new DHTML features cannot be taken advantage of until the company that creates your editor publishes a version that exploits those advancements for you. Most likely they'll charge for the upgrade. Meanwhile, other designers who can write their own DHTML code are able to exploit advancements as soon as they are supported in web browsers.
Tools may write unnaturally complex code. Tools may make some processes more complex than they need to be, for instance, creating custom objects when they're not necessary.
Copyright © 2002 O'Reilly & Associates. All rights reserved.