tailieunhanh - JavaScript Bible, Gold Edition part 103
JavaScript Bible, Gold Edition part 103. This book will bring programmers and non-technical professionals, including casual programmers and scripters, painlessly up to speed on all aspects of mastering JavaScript. Key topics include programming fundamentals, JavaScript language elements and how to use them effectively, and how to easily and efficiently add powerful new functionality to HTML documents and Java applets. | 868 Part III Document Objects Reference Netscape also provides the layerObject .load method to insert new content into a layer. One advantage of this method is that an optional second parameter enables you to redefine the width of the layer at the same time you specify a new document. But if you are simply replacing the content in the same width layer you can use either way of loading new content. Be aware that the height and width of a replacement layer are governed as much by their hard-coded content size as by the initial loading of any layer. For example if your layer is initially sized at a width of 200 pixels and your replacement layer document includes an image whose width is set to 500 pixels the layer expands its width to accommodate the larger content unless you also restrict the view of the layer via the layerObject .clip properties. Similarly longer text content flows beyond the bottom of the previously sized layer unless restricted by clipping properties. Positioned elements in IE4 and NN6 do provide a way to load external content into them. That s what the W3C sees as the purpose of the IFRAME element. Even so as Listing 31-18 shows you can script your way around this limitation if it s absolutely necessary. Example with Listing 31-7 on the CD-ROM On the CD-ROm Related Items methods. visibility Value String Read Write NN2 NN3 NN4 NN6 IE3 J1 IE3 J2 IE4 IE5 Compatibility A layer s visibility property can use one of three settings show hide or inherit the same values you can assign to the VISIBILITY attribute of the LAYER tag. But NN4 also enables you to set the property to hidden and visible which are the values for the property used in IE4 and NN6 . Unlike many other layer properties you can set the visibility property such that a layer can either follow the behavior of its parent or strike out on its own. By default a layer s visibility property is set to inherit which means the layer s visibility is .
đang nạp các trang xem trước