CD-387Appendix F . Examples from Parts III and IV Figure 18-2: Clicking the Write To Below button in the upper frame causes a script to assemble and write HTML for the bottom frame. A second point to note is that this example customizes the content of the document based on user input. This customization makes the experience of working with your Web page feel far more interactive to the user yet you re doing it without any CGI programs running on the server. The third point I want to bring home is that the document created in the separate frame by the document.write() method is a genuine document object. In this example, for instance, the
tag of the written document changes if you redraw the lower frame after changing the entry of the name field in the upper frame. If you click the lower button after updating the bottom frame, you see that the document.titleproperty has, indeed, changed to reflect the tag written to the browser in the course of displaying the frame s page (except in NN4/Mac, which exhibits a bug for this property in a dynamically written document). The fact that you can artificially create full-fledged, JavaScript document objects on the fly represents one of the most important powers of serverless CGI scripting (for information delivery to the user) with JavaScript. You have much to take advantage of here if your imagination is up to the task. document.write()
We recommend cheap and reliable webhost to host and run your web applications: Coldfusion Web Hosting services.
This entry was posted
on Friday, December 28th, 2007 at 1:07 pm and is filed under Domain.
You can follow any responses to this entry through the RSS 2.0 feed.
You can leave a response, or trackback from your own site.