RE: [xsl] Insert space after the closing element

Subject: RE: [xsl] Insert space after the closing element
From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx>
Date: Fri, 22 Jan 2010 12:08:09 -0500
Dear Selva,

At 11:05 AM 1/22/2010, you wrote:
Hi Michael,

Sorry, I was trid as below coding it was show the error as (Element type "hov:if" must be followed by either attribute specification, ">" or "/>")

<hov:template match="legis-cite">
<hov:text> </hov:text>
<hov:element name="citation">
<hov:apply-templates/>
</hov:element>
<hov:if test="not(matches(following-sibling::text()[1], "^[-,:;;]"))"><hov:text> </hov:text></hov:if>
</hov:template>


Kindly correct the above line

I know it's none of my business, but if you'd posted this to me, I would find it to be an imposition.


What you have is a simple syntax error in your code. Asking Mike Kay to fix it is like asking a full professor of mathematics to fix your arithmetic homework. (To put it mildly.)

That aside, on the list we generally discourage addressing questions to individual members, even when they've helped us in the past. It isn't fair, either to them or to others.

You might get a better response if you'd written, to all of us, "I'm having trouble seeing the error here: what am I missing?"

On the other hand, since your XML won't even parse, this isn't really even an XSL question, and thus not on topic for the list.

Regards,
Wendell

p.s. try <hov:if test="not(matches(following-sibling::text()[1], '^[-,:;;]'))">

Your attempt does not parse because your attribute is not delimited correctly. Using a different form of quote mark inside it deals with this problem.



======================================================================
Wendell Piez                            mailto:wapiez@xxxxxxxxxxxxxxxx
Mulberry Technologies, Inc.                http://www.mulberrytech.com
17 West Jefferson Street                    Direct Phone: 301/315-9635
Suite 207                                          Phone: 301/315-9631
Rockville, MD  20850                                 Fax: 301/315-8285
----------------------------------------------------------------------
  Mulberry Technologies: A Consultancy Specializing in SGML and XML
======================================================================

Current Thread