20 CHAPTER HTML Directive Objects …. Thanks to (Php web hosting)
Friday, July 27th, 200720 CHAPTER HTML Directive Objects …. Thanks to the modern browser s desire to expose all HTML elements to the document object model, we can now (in IE4+ and NN6) access a variety of objects that represent many HTML elements that are normally invisible to the human viewer of a page. These elements are called directive elements because they predominantly contain instructions for the browser instructions that direct the browser to locate associated content on the page, link in external specifications, treat content as executable script statements, and more. As you browse through the objects of this chapter, you may wonder why they have so many properties that normally indicate that the elements occupy space on the rendered page. After all, how can a META element have dimension or position on the page when it has no renderable content? The reason is that modern browsers internally employ some form of object- oriented behavior that lets all HTML elements rendered or not inherit the same set of properties, methods, and event handlers that any generic element has (see Chapter 15). The logical flaw is that unrendered elements can have properties and methods that don t genuinely apply to them. In such cases, their property values may be zero, an empty string, or an empty array. Yet the properties and methods exist in the objects just the same. Therefore, despite the large number of objects covered in this chapter, there are relatively few properties and methods that are not shared already with all HTML elements (as covered in Chapter 15). HTML Element Object For HTML element properties, methods, and event handlers, see Chapter 15. In This Chapter Accessing non- displayed element objects Linking operating- system specific style sheet definitions HTML, HEAD, LINK, TITLE, META, BASE, and SCRIPT elements …. Properties Methods Event Handlers version
Visit our web design programs services for an affordable and reliable webhost to suit all your needs.