xml-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dan Morrison <d...@es.co.nz>
Subject How to use XML to link to XML when the XML becomes HTML?
Date Thu, 30 Mar 2000 07:42:38 GMT
Sorry if this is off-topic, but I can't find an XLINK forum, can anyone
suggest where to look?

So far I've been labouring under the impression that Xlink is some sort
of enhanced replacement for <a href=""> tags. After reading the spec &
lots of surrounding vapourware articles, I'm more confused than ever.

I have a collection of XML docs, in a file heirachy analogous to a
website structure. I have a process which formats all these docs using
multiple XSLs and produces a complete site of html docs.
These documents naturally refer to each other sometimes. Much of the
navigation is automatic, but I still need <a href> now and then.


Problem:
I CAN get my index.xml to refer to contentpage.xml using some
complicated XSL, although it involves renaming the link from
contentpage.xml to contentpage.html. This is conceptually very messy.

So I imagine some advanced link syntax in my source docs
<LINK path="/my/content/" targetname="contentpage">content</LINK>

which my stylesheet can convert to 
	<a href="/my/content/contentpage.html">
when it feels like, or alternatively refer to 
	/pdfs/my/content/contentpage.pdf
or
	/my/content/contentpage.phtml
etc etc in the future.


Question:
Is the complicated link syntax Xlink? Is that what Xlink can do for me?
If so, are there actually any extant examples to work from?

The examples in the spec
------------------------------------
<A xmlns:xlink="http://www.w3.org/XML/XLink/0.9" xlink:type="simple"
	xlink:href="students.xml" xlink:role="student list"
	xlink:title="Student List" xlink:show="new" xlink:actuate="user">
	Current List of Students
</A>
 
<xlink:simple href="students.xml" role="student list"
	title="Student List" show="replace" actuate="user">
	Current List of Students
</xlink:simple>
-------------------------------------
Don't quite do it for me (that hard-coded href="xxx.xml" defeats the
transformation). And I'm not clear enough on namespaces to understand
which method I'd use in a basic xml doc.

I can just make it all up, but I prefer to start from some sort of a
standard naming convention. (Trying against the odds to do things the
Right Way[tm])

TIA
regards,

.dan.

 
:=====================:====================:
: Dan Morrison        : The Web Limited    :
:  http://here.is/dan :  http://web.co.nz  :
:  dman@es.co.nz      :  danm@web.co.nz    :
:  04 384 1472        :  04 495 8250       :
:  021 115 7339       :                    :
:.....................:....................:
: If ignorance is bliss, why aren't more people happy?
:.........................................:

Mime
View raw message