phantom generated text in hyperlink fields

L

larrysulky

Here's one of the freakiest things I've seen MS Word 2000 on Win2000
do:

The author has submitted a document with hypertext links as fields.
They innocently look like this:

<URL>www.e-laws.gov.on.ca/DBLaws/Statutes/English/90e23_e.htm</URL>

The final </URL> tag is not part of the link, but the <URL> tag at the
beginning is. This is odd, I think, and troublesome because I have to
do some find and replace stuff based on the tagging. So I show the
field codes. Here's what I see:

{ HYPERLINK
"http://www.e-laws.gov.on.ca/DBLaws/Statutes/English/90e23_e.htm"
}</URL>

The leading <URL> tag isn't in the hyperlink field. BUT IT ISN'T IN THE
PLAIN TEXT EITHER. It's somehow being generated by the hyperlink field
itself. But when I insert a test hyperlink myself, like this one:

{ HYPERLINK "http://www.verypdf.com/" }

and then hide the field codes, I just get:

www.verypdf.com/

I don't get any autogenerated "<URL>"... but I still do for the other
hyperlink! So I save the document as RTF and look inside using an ASCII
text editor. I get:

{\field\fldedit{\*\fldinst {\f28\fs18\lang4105\langfe1033\langnp4105
HYPERLINK
"http://www.e-laws.gov.on.ca/DBLaws/Statutes/English/90e23_e.htm" }

and

{\field\fldedit{\*\fldinst {\f28\fs18\lang4105\langfe1033\langnp4105
HYPERLINK "http://www.verypdf.com/" }

The two links are identical in form. The first one somehow knows to
generate "<URL>" at the outset, the second one, which I added myself,
doesn't.

So then I save as HTML. Within Word I still get the same result as
before, but if I look inside the file using the ASCII text editor, I
get:

<a
href="http://www.e-laws.gov.on.ca/DBLaws/Statutes/English/90e23_e.htm">&lt;URL&gt;www.e-laws.gov.on.ca/DBLaws/Statutes/English/90e23_e.htm</a>

and

<a href="http://www.verypdf.com/">www.verypdf.com/</a>

So as HTML "<URL>" appears in the first link, not in the second, when
seen in an ASCII text editor. But not when looking at the document
within Word itself.

Where is this <URL> tag coming from???!!! It isn't an isolated case.
ALL the links that the author put in do this. How is this in any way
possible??? I can scarcely believe my own eyes, but believe me, that
<URL> tag is not, repeat NOT, repeat ABSOLUTELY NOT in the main text.
It is part of the generated hyperlink text, but is not part of the
hyperlink itself. Except when saved as HTML and viewed in an ASCII text
editor!

This is more than just weird. It's blocking me from setting up the
macros I need to globally modify the text around these links. Any
ideas, anyone?

---larry
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top