replacing cdata in nodes q.

Well, sort of.
 
I'm writing a XSL sheet to process a large volume of XML files into HTML.
Every XML file has a node ("Summary") which contains a large block of text.
Within that text, there are various reference numbers (these are scientific
documents) in the format [1234567]. What I need to do is have each occurance
of the ref. number wrapped in a <a href="1234567"></a> in the resulting
HTML. Unfortunately I can't search for a certain string of digits, as the
reference numbers are not always 7 characters long - so what I need to do is
have a template which looks for the square brackets, and returns what is
held inside them to the result tree like so: [<a
href="1234567">1234567</a>].
 
I am, unfortunately, clueless as to how I would go about searching through a
large body of text in XSL. Can anybody point me in the right direction?
 
{FYI - we are aware that this is a very clunky thing to be doing. New data
added to the database will have these references marked up as <ref/>, and we
are looking into converting the legacy data to this format.
 
Thanks in advance,
 
Kerin

Received on Friday, 1 June 2001 05:34:22 UTC