252Part IIIDocument Objects ReferenceExampleTo change a style (Web hosting domain names) property
Saturday, November 10th, 2007252Part IIIDocument Objects ReferenceExampleTo change a style property setting, access it via the element s styleobject. Use The Evaluator(Chapter 13) to compare the properties of the runtimeStyleand styleobjects of an element. For example, an unmodified copy of The Evaluator contains an emelement whose ID is myEM . Enter both document.getElementById( myEM ).style.color anddocument.getElementById( myEM ).runtimeStyle.color into the top text field in turn. Initially, both values are empty. Now assign a color to the styleproperty via the upper text box: document.getElementById( myEM ).style.color = red If you now type the two earlier statements into the upper box, you can see that the styleobject reflects the change, while the runtimeStyleobject still holds onto its original(empty) value. Related Items:currentStyleproperty; styleobject (Chapter 26). scopeNameValue:String.Read-Only Compatibility:WinIE5+, MacIE-, NN-, Moz-, Safari- The scopeNameproperty is associated primarily with XML that is embedded within a document. When you include XML, you can specify one or more XML Namespaces that define the owner of a custom tag name, thus aiming toward preventing conflicts of identical custom tags from dif- ferent sources in a document. (See Chapter 41 on the CD-ROM for more about XML objects.) The XML Namespace is assigned as an attribute of the tag that surrounds the entiredocument: After that, the Namespace value precedes all custom tags linked to that Namespace: