Represents a Processing Instruction in an XML document.
Browser/User Agent Support
| IE | Mozilla | Netscape | Opera | Safari | Netscapte | no | 1.0+ | 7.0+ | no | no | no |
|---|
Constructors
| Constructor | IE | Mozilla | Netscape | Opera | Safari | Netscapte |
|---|---|---|---|---|---|---|
Represents a Processing Instruction in an XML document. | no | 1.0+ | 7.0+ | no | no | no |
Properties
| Property | IE | Mozilla | Netscape | Opera | Safari | Netscapte |
|---|---|---|---|---|---|---|
PI data or content | no | 1.0+ | 7.0+ | no | no | no |
PI target name | no | 1.0+ | 7.0+ | no | no | no |
Remarks
Represents a Processing Instruction, which is a way to keep document processing information inside an XML document. For instance, instructions on which stylesheets to apply can be defined in a processing instruction, even though that isn't directly related to the content of the document.
Availability
HTML DOM Level 1 | HTML DOM Level 2 | W3C
Constructor Detail
ProcessingInstruction ProcessingInstruction()
Represents a Processing Instruction in an XML document.
- Visibility
- internal
Property Detail
String data
PI data or content
-
For examples, see the quirksmode test page:
- Remarks
- Represents the content data of a processing instruction. This is the entire text between the
targetname and the closing?>tag. Setting this value throws an exception if this node is marked as read-only. - Availability
HTML DOM Level 1 | HTML DOM Level 2 | W3C
String target - read only
PI target name
- Remarks
- This is the name of this processing instruction. This is the text immediately following
<?and and before thedata. - Availability
HTML DOM Level 1 | HTML DOM Level 2 | W3C
