On Fri, 13 Apr 2001, Murray Altheim wrote:
> Maybe I'm not understanding this correctly, so please elaborate. If one
> preprocesses an HTML file to add the hID and sID links, the result is a
> document with an overlay of structural and sequential links representative
> of the structure of the document at the time the process was run. If an
> editor adds a third paragraph to section four, what was, say, "D3 (12)"
> now becomes "D4 (13)". Links made to this paragraph in earlier versions
> of the document now point to the newly added paragraph.
Nope. The proper behavior should be that "D3 (12)" becomes "D4 (12)".
First, a clarification in terminology. "s" in "sid" stands for
"statement", not "sequential." "Statement ID" is Augment terminology for
a permanent ID assigned to a statement (i.e. a paragraph). In most of the
documents on my Web site that were generated with Purple, the SIDs happen
to be sequential, because that is how they were initially assigned.
However, some of the documents that have been updated do have out of
sequence SIDs. For example, take a look at:
http://www.eekim.com/cgi-bin/dkr?fn=/ohs/usecases.html#2C4
Paragraph 2C4 has an SID of 017, but paragraph 2D has an SID of 054.
> Is there something in the way Purple works that avoids this? Doesn't
> adding or deleting paragraphs break links made to earlier versions of
> these targets?
Links to hierarchical IDs always have the potential to break. Links to
statement IDs won't break if new paragraphs are added, although they will
break if paragraphs are deleted. So I wrote a CGI script to provide a
workaround. dkr takes a "v" attribute to designate a version of a
document. For instance, to see the original version of the Use Cases
document above, go to:
http://www.eekim.com/cgi-bin/dkr?fn=/ohs/usecases.html&v=1.0
So if you really want to prevent links from breaking, include the version
parameter in your link tags.
The methodology for versioning using Purple is described here:
http://www.eekim.com/software/purple/purple.html#027
However, to summarize briefly:
1. Create an XML document with no IDs.
2. Run add_ids.pl to add statement IDs and compute hierarchical IDs.
3. Publish document.
4. When editing the document, don't delete the old statement IDs. Also,
don't give new paragraphs statement IDs.
5. Run add_ids.pl again. This will leave the old statement IDs alone, add
new ones to new paragraphs, and recompute all the hierarchical IDs.
6. Publish the new document.
-Eugene
-- +=== Eugene Eric Kim ===== eekim@eekim.com ===== http://www.eekim.com/ ===+ | "Writer's block is a fancy term made up by whiners so they | +===== can have an excuse to drink alcohol." --Steve Martin ===========+
This archive was generated by hypermail 2.0.0 : Tue Aug 21 2001 - 17:58:04 PDT