XLink defines a standard way to create hyperlinks in an XML document.
XPointer allows these hyperlinks to point to more specific parts (fragments) in an XML document.
Xlink
XLink is an abbreviation for the XML link language (XML linking Language)
XLink is the language used to create hyperlinks in an XML document
XLink is similar to HTML links-but more powerful
Any element in an XML document can be a XLink
XLink supports easy links, as well as extended links to link multiple resources together
Links can be defined outside the linked file via XLink
XLink is the recommended standard for the consortium
XPointer
XPointer is an abbreviation for an XML pointer file (XML Pointer Language)
XPointer enables hyperlinks to point to more specific parts of an XML document (fragment)
XPointer using XPath expressions to locate in an XML document
XPointer is the recommended standard for the consortium
XLink is an abbreviation for the XML link language (XML linking Language)
XLink is the language used to create hyperlinks in an XML document
XLink is similar to HTML links-but more powerful
Any element in an XML document can be a XLink
XLink supports easy links, as well as extended links to link multiple resources together
Links can be defined outside the linked file via XLink
XLink is the recommended standard for the consortium
XLink Syntax:
In order to access the properties and attributes of XLink, the XLink namespace must be declared at the top of the document.
The XLink namespace is: "Http://www.w3.org/1999/xlink".
The Xlink:type and Xlink:href properties define the type and HREF attributes from the XLink namespace.
Xlink:type= "Simple" creates an easy two-way link (meaning "From here to where"). We'll look at multi-link (multi-directional) later.
XPointer
You can add the XPointer section to the URL in the Xlink:href property so that you can navigate (through an XPath expression) to a specific location in the document.
For example, in the following example, we use XPointer to point to the fifth item in a list by using the unique ID "rock".
Href=http://www.example.com/cdlist.xml#id (' Rock '). Child (5,item)
The Xlink:show property specifies where to open the link. xlink:show= "new" means a link
XLink Property Reference Manual
Property |
Value |
Describe |
Xlink:actuate |
OnLoad ONrequest Other None |
Defines when the linked resource is read and displayed. |
Xlink:href |
Url |
The URL to link to. |
Xlink:show |
Embed New Replace Other None |
Where to open the link. Replace is the default value. |
Xlink:type |
Simple Extended Locator Arc Resource Title None |
The type of the link. |
XLink and XPoint