cocoon-docs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject [DAISY] Updated: LinkRewriterTransformer
Date Mon, 14 Apr 2008 13:05:09 GMT
A document has been updated:

Document ID: 1102
Branch: main
Language: default
Name: LinkRewriterTransformer (unchanged)
Document Type: Sitemap Component (unchanged)
Updated on: 4/9/08 9:39:38 PM
Updated by: Grzegorz Kossakowski

A new version has been created, state: draft


Long description
This part has been updated.
Mime type: text/xml (unchanged)
File name:  (unchanged)
Size: 6648 bytes (previous version: 6651 bytes)
Content diff:
--- <p><strong>Example</strong></p>
+++ <h3><strong>Example</strong></h3>
    <p>For instance, if we had an
    <a href="">XMLFileModule</a>,
(4 equal lines skipped)
         &lt;how_to_boil_eggs href="faq/eggs.html"/&gt;
---  </pre>
+++ </pre>
    <p>mapped to the prefix 'site:', then &lt;link
    href="site:/site/faq/how_to_boil_eggs/@href"&gt; would be replaced with &lt;link
(58 equal lines skipped)
          &lt;map:transform type="linkrewriter" src="cocoon:/{1}linkmap"/&gt;
          &lt;map:serialize type="xml"/&gt;
---  </pre>
+++ </pre>
    <p>Which would cause the 'mapper' XMLFileModule to be configured with a
    different XML file, depending on the request.</p>
    <p>Similarly, we could use a dynamic prefix:</p>
    <pre>   &lt;prefix&gt;{prefix}&lt;/prefix&gt;
---  </pre>
+++ </pre>
    <p>in the template config, and:</p>
    <pre>   &lt;map:parameter name="prefix" value="/site/"/&gt;
---  </pre>
+++ </pre>
    <p>in the map:transform</p>
(38 equal lines skipped)
         &lt;link-attr name="target" pattern="(?:url\((.*?)\).*?){1,2}$"/&gt;
         &lt;!-- additional configuration ... --&gt;
---  </pre>
+++ </pre>
    <p>When matched against the value of target attribute above, the parenthesized
    expressions are:<br/>
(17 equal lines skipped)

View raw message