Author: crossley
Date: Mon Aug 11 22:33:44 2008
New Revision: 685044
URL: http://svn.apache.org/viewvc?rev=685044&view=rev
Log:
Add workaround for FOR-1088 - use xpointer as separate attribute.
Added:
forrest/trunk/main/webapp/resources/stylesheets/replace-xpointer-attributes.xsl
(with props)
Modified:
forrest/trunk/main/fresh-site/src/documentation/content/xdocs/samples-b/xinclude-explanation.xml
forrest/trunk/main/fresh-site/src/documentation/content/xdocs/samples-b/xinclude.xml
forrest/trunk/main/webapp/resources/schema/dtd/document-v20.mod
forrest/trunk/main/webapp/sitemap.xmap
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/dataModel.xmap
Modified:
forrest/trunk/main/fresh-site/src/documentation/content/xdocs/samples-b/xinclude-explanation.xml
URL:
http://svn.apache.org/viewvc/forrest/trunk/main/fresh-site/src/documentation/content/xdocs/samples-b/xinclude-explanation.xml?rev=685044&r1=685043&r2=685044&view=diff
==============================================================================
---
forrest/trunk/main/fresh-site/src/documentation/content/xdocs/samples-b/xinclude-explanation.xml
(original)
+++
forrest/trunk/main/fresh-site/src/documentation/content/xdocs/samples-b/xinclude-explanation.xml
Mon Aug 11 22:33:44 2008
@@ -41,7 +41,8 @@
<xi:include href="cocoon://samples-b/xinclude-input-sec2.xml"/>
<section>
<title>Section 3</title>
- <xi:include
href="cocoon://samples-b/xinclude-input-sec3.xml#xpointer(/section/p)"/>
+ <xi:include href="cocoon://samples-b/xinclude-input-sec3.xml"
+ xpointer="xpointer(/section/p)"/>
</section>
<section>
<title>Section 4</title>
Modified:
forrest/trunk/main/fresh-site/src/documentation/content/xdocs/samples-b/xinclude.xml
URL:
http://svn.apache.org/viewvc/forrest/trunk/main/fresh-site/src/documentation/content/xdocs/samples-b/xinclude.xml?rev=685044&r1=685043&r2=685044&view=diff
==============================================================================
---
forrest/trunk/main/fresh-site/src/documentation/content/xdocs/samples-b/xinclude.xml
(original)
+++
forrest/trunk/main/fresh-site/src/documentation/content/xdocs/samples-b/xinclude.xml
Mon Aug 11 22:33:44 2008
@@ -47,7 +47,8 @@
<xi:include href="cocoon://samples-b/xinclude-input-sec2.xml"/>
<section>
<title>Section 3</title>
- <xi:include
href="cocoon://samples-b/xinclude-input-sec3.xml#xpointer(/section/p)"/>
+ <xi:include href="cocoon://samples-b/xinclude-input-sec3.xml"
+ xpointer="xpointer(/section/p)"/>
</section>
<section>
<title>Section 4</title>
Modified: forrest/trunk/main/webapp/resources/schema/dtd/document-v20.mod
URL:
http://svn.apache.org/viewvc/forrest/trunk/main/webapp/resources/schema/dtd/document-v20.mod?rev=685044&r1=685043&r2=685044&view=diff
==============================================================================
--- forrest/trunk/main/webapp/resources/schema/dtd/document-v20.mod (original)
+++ forrest/trunk/main/webapp/resources/schema/dtd/document-v20.mod Mon Aug 11
22:33:44 2008
@@ -228,6 +228,7 @@
<!ATTLIST xi:include
parse (text|xml) "xml"
href CDATA #REQUIRED
+ xpointer CDATA #IMPLIED
encoding CDATA #IMPLIED
>
Added:
forrest/trunk/main/webapp/resources/stylesheets/replace-xpointer-attributes.xsl
URL:
http://svn.apache.org/viewvc/forrest/trunk/main/webapp/resources/stylesheets/replace-xpointer-attributes.xsl?rev=685044&view=auto
==============================================================================
---
forrest/trunk/main/webapp/resources/stylesheets/replace-xpointer-attributes.xsl
(added)
+++
forrest/trunk/main/webapp/resources/stylesheets/replace-xpointer-attributes.xsl
Mon Aug 11 22:33:44 2008
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<xsl:stylesheet version="1.0"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:xi="http://www.w3.org/2001/XInclude">
+
+ <xsl:import href="copyover.xsl"/>
+
+ <!-- See FOR-1088 -->
+ <xsl:template match="xi:include/@xpointer">
+ <xsl:attribute name="href">
+ <xsl:value-of select="../@href"/>
+ <xsl:text>#</xsl:text>
+ <xsl:value-of select="."/>
+ </xsl:attribute>
+ </xsl:template>
+</xsl:stylesheet>
Propchange:
forrest/trunk/main/webapp/resources/stylesheets/replace-xpointer-attributes.xsl
------------------------------------------------------------------------------
svn:eol-style = native
Modified: forrest/trunk/main/webapp/sitemap.xmap
URL:
http://svn.apache.org/viewvc/forrest/trunk/main/webapp/sitemap.xmap?rev=685044&r1=685043&r2=685044&view=diff
==============================================================================
--- forrest/trunk/main/webapp/sitemap.xmap (original)
+++ forrest/trunk/main/webapp/sitemap.xmap Mon Aug 11 22:33:44 2008
@@ -493,6 +493,9 @@
<map:match pattern="**body-*.html">
<map:generate src="cocoon:/{1}{2}.xml"/>
<map:transform type="idgen"/>
+ <!-- Start fix for FOR-1088 -->
+ <map:transform src="{lm:transform.xml.xml-xpointer-attributes}"/>
+ <!-- End fix for FOR-1088 -->
<map:transform type="xinclude"/>
<map:transform type="linkrewriter" src="cocoon:/{1}linkmap-{2}.html"/>
<map:transform src="{lm:transform.html.broken-links}" />
Modified:
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/dataModel.xmap
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/dataModel.xmap?rev=685044&r1=685043&r2=685044&view=diff
==============================================================================
---
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/dataModel.xmap
(original)
+++
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/dataModel.xmap
Mon Aug 11 22:33:44 2008
@@ -39,6 +39,9 @@
<map:match pattern="**.source.rewritten.xml">
<map:generate src="cocoon://{1}.xml" />
<map:transform type="idgen" />
+ <!-- Start fix for FOR-1088 -->
+ <map:transform src="{lm:transform.xml.xml-xpointer-attributes}"/>
+ <!-- End fix for FOR-1088 -->
<map:transform type="xinclude" />
<map:match pattern="**/*.source.rewritten.xml">
<map:transform type="linkrewriter" src="cocoon://{1}/linkmap-{2}" />