xml-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Dierken <m...@DataChannel.com>
Subject RE: How to use XML to link to XML when the XML becomes HTML?
Date Fri, 31 Mar 2000 17:04:01 GMT
This is a very critical area of XML technology, not widely understood or
But that just makes it all the more fun.

Not all XML will be generated by something that knows which pieces will be
used as a link. Some XML generators (files, databases, etc.) will express
their knowledge of links to other pieces of information either explicitly
with some standard syntax (XLink,etc) or implicitly via some other mechanism
(we all know 'href' means something.)

But the XML generator is not the one that 'de-references' the link. The
'link processor' might choose to ignore XLink, or look for href attributes,
or grab fragments of text or whatever. Pushing things to an explicit
declaration is good, but not achievable.

In the case where an XML generator knows which pieces of itself are
references to other pieces elsewhere, it will express that knowledge in the
format that the link processor & 'de-reference' processor can deal with.
When you author HTML, you know the algorithm that a browser will use to do
thing. When you author XML, you don't know the algorithm that a
'link/reference' processor will use. And if you chain these processors,
things get more complex. Passing XML to a parser, then processor, then
transformer, then browser is a problem. At each stage, referencing &
de-references need to be defined. In the case of HTML in Web browsers, we
know what will happen there, so we might be able work backwards to the
source & define the layers. I'm not sure yet how that would look.

The de-referencing seems to be associated with crossing storage fragment
If you have one large mega-document, the references are 'internal'. If you
have many small documents, the references are 'external'. This sucks. A
processor should be able to traverse this without knowing about the

I think I've rambled enough... didn't get anywhere but it's interesting.

Mike D

> -----Original Message-----
> From: Stefano Mazzocchi [mailto:stefano@apache.org]
> Sent: Friday, March 31, 2000 2:49 AM
> To: general@xml.apache.org
> Subject: Re: How to use XML to link to XML when the XML becomes HTML?
> Dan Morrison wrote:
> > 
> > Tim Bray wrote:
> > > What you're doing is transforming links as part of the 
> publishing or
> > > delivery process.  A common-enough thing to want to do.  
> If XSLT has
> > > trouble in doing what you want, then that is probably a 
> shortcoming
> > > of XSLT.  XLink is just syntax for describing links, not 
> a framework
> > > for transforming them. -Tim
> > 
> > I just want my link relationships to be stated in a generic 
> enough way
> > to survive a global change of suffix.
> > 
> > I take this to mean that I should work on leveraging my XSLT to mess
> > around with href attributes s/\.xml$/\.html/ etc. OK, I 
> didn't want to
> > be playing with substrings (which sure is a shortcoming 
> with XSL) but
> > I'll manage.
> > 
> > I therefore take it that Xlink can draw no implicit 
> relationship at all
> > between doc.xml and doc.html without such a relationship 
> being stated on
> > a one-by-one basis in some external link file.
> > The filenames are different, therefore they are different 
> objects. It'd
> > be fun if I could throw some wildcarding into the filename but my
> > reading of the spec didn't see that.
> > 
> > ... hmm, what if I set up a directory structure with every 
> 'file' being
> > a directory containing multiple versions of the same 
> content then used
> > content negotiation to... [shudder]. Yuk.
> > 
> > I'm looking forward to using the extended link syntax for
> > cross-referencing keyword lookups, but I've never seen a UI 
> that does
> > this. Has anyone ever made an example of practical, multi-targeted
> > extended links (beyond content-negotiation)?
> This is a big issue and I still don't have a clear-cut vision on the
> problem.
> I hope that others (Tim at first) can share opinions over 
> this one which
> is a very nasty issue.
> Situation: consider you are a site manager and you tell your document
> writers to write XML documentation. You give them the 
> DTD/Schema and you
> tell them what they should write. Suppose they need to link each-other
> work.
> Possibilities:
>  - "hard" link points to "doc1.xml"
>  - "soft" link points to "doc1.xml"
> this can be done with [role="hard|soft"] as an attribute of your
> XLink-ed element.
> "Hard" means that the link is not touched, while "soft" means that the
> link has a meaning in the context of document writing: doc2.xml knows
> that the file name on the dist is doc1.xml, but doesn't know where the
> document will reside after deployment on the publishing URI space.
> So, by allowing "soft" links on the server side, we remove a 
> "contract"
> between the site managers and the document writers.
> Still questions remain on "how" link translation is 
> performed, but this
> is an implementation detail.
> The question is: do "soft" links break the hyperlinking paradigm
> altogether?
> I mean: should those URI contracts be "enforced" as DTDs to 
> the document
> writers?
> NOTE: don't get me wrong, this is _NOT_ a discussion about "extention
> translation" like written above. That arguments doesn't count: you
> should _NEVER_ use extentions in your URIs and if you do you're not
> getting the URI idea alltogether.
> Browsers should access
>  /home/stefano/index
> and publishing engines (apache + cocoon) should take care of mapping
> this "resource" to the appropriate generation procedure. If this
> requires loading the file "index.xml" or "default.htm" or 
> even accessing
> the index from a database and generate the XML from there, 
> this is _NOT_
> a concern that who writes the index.xml file should have.
> And links are _NOT_ something that you should mess around with with
> something like XSLT processors.
> The idea is to have links on the server side that are "streched" while
> being published to match the URI space.
> And I'm not sure this is a good thing to do.
> Comments?
> -- 
> Stefano Mazzocchi      One must still have chaos in oneself to be
>                           able to give birth to a dancing star.
> <stefano@apache.org>                             Friedrich Nietzsche
> --------------------------------------------------------------------
>  Missed us in Orlando? Make it up with ApacheCON Europe in London!
> ------------------------- http://ApacheCon.Com ---------------------
> ---------------------------------------------------------------------
> In case of troubles, e-mail:     webmaster@xml.apache.org
> To unsubscribe, e-mail:          general-unsubscribe@xml.apache.org
> For additional commands, e-mail: general-help@xml.apache.org

View raw message