Just a hunch, I could be totally wrong on this, but... 

I wonder if you now require double '\\' instead of single '\' in your
pattern? I've come across versions of XML parsers where it (incorrectly I
think) interprets the '\' as an escape character inside a quoted string. If
the xml parser is interpreting '\' as an escape, then your regex pattern may
become invalid. Do you explicitly set the encoding attibute for the xml PI?
(eg. <?xml version="1.0" encoding="UTF-8"?>)

The reason why I suggest this is that I've come across a similar problem in
my log4j xml configuration files when an attribute value contains a '\'. I
had to use '\\' to get the dos-style path to be interpreted correctly.

Regards,

--mike

-----Original Message-----
From: Wes Morgan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, July 24, 2001 2:47 PM
To: [EMAIL PROTECTED]
Subject: [C2b2] Is regexp broken in b2?


Here's the <map:pipelines> section of my sitemap which was working fine 
under Cocoon2.0b1:

 <map:pipelines>

  <map:pipeline>

    <map:match type="regexp" 
pattern="([a-z])(.*)/([a-zA-Z0-9\-]*)\.(.*)\.html">
      <map:select type="parameter">
        <map:parameter name="parameter-selector-test" value="{4}"/>
        <map:when test="about">
          <map:generate src="{1}/{1}{2}/{3}.xml"/>
          <map:transform src="xsl/about.html.xsl"/>
        </map:when>
        <map:when test="all">
          <map:generate src="{1}/{1}{2}/{3}.xml"/>
          <map:transform src="xsl/all.html.xsl"/>
        </map:when>
        <map:when test="toc">
          <map:select type="browser">
            <map:when test="gecko">
              <map:generate src="{1}/{1}{2}/{3}.xml"/>
              <map:transform src="xsl/toc.dom1.html.xsl"/>
            </map:when>
            <map:when test="ie5up">
              <map:generate src="{1}/{1}{2}/{3}.xml"/>
              <map:transform src="xsl/toc.dom1.html.xsl"/>
            </map:when>
            <map:when test="nn4">
              <map:generate src="{1}/{1}{2}/{3}.xml"/>
              <map:transform src="xsl/toc.xbstyle.html.xsl"/>
            </map:when>
            <map:otherwise>
              <map:generate src="{1}/{1}{2}/{3}.xml"/>
              <map:transform src="xsl/toc.other.html.xsl"/>
            </map:otherwise>
          </map:select>
        </map:when>
        <map:otherwise>
          <map:generate src="{1}/{1}{2}/{3}.xml"/>
          <map:transform src="xsl/page.html.xsl">
            <map:parameter name="idRequest" value="{4}"/>
          </map:transform>
        </map:otherwise>
      </map:select>
      <map:serialize/>
    </map:match>

    <map:match type="regexp" pattern="([a-z])(.*)/index\.html">
      <map:generate src="{1}/{1}{2}/authInfo.xml"/>
      <map:transform src="xsl/author.html.xsl"/>
      <map:serialize type="html"/>
    </map:match>

    <map:match type="regexp" pattern="([a-z])(.*)/([a-zA-Z0-9\-]*)\.html">
      <map:generate src="{1}/{1}{2}/{3}.xml"/>
      <map:transform src="xsl/about.html.xsl"/>
      <map:serialize type="html"/>
    </map:match>

    <map:match type="regexp" pattern="([a-z])(.*)/([a-zA-Z0-9\-]*)\.css">
      <map:generate src="{1}/{1}{2}/{3}.xml"/>
      <map:transform src="xsl/xcss.css.xsl"/>
      <map:serialize type="text"/>
    </map:match>

    <map:match type="regexp" pattern="([a-z])(.*)/([a-zA-Z0-9\-]*)\.thml">
      <map:generate src="{1}/{1}{2}/{3}.xml"/>
      <map:serialize type="xml"/>
    </map:match>

    <map:match type="regexp" pattern="([a-z])(.*)/([a-zA-Z0-9\-]*)\.pdf">
      <map:generate src="{1}/{1}{2}/{3}.xml"/>
      <map:transform src="xsl/all.fo.xsl">
      </map:transform>
      <map:serialize type="fo2pdf"/>
    </map:match>

  </map:pipeline>

 </map:pipelines>

I get lots of "Invalid escape character" errors under Cocoon2 beta2. Any 
help would be much appreciated, thanks.

Wes Morgan


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to