forrest-svn mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cdupoiri...@apache.org
Subject svn commit: r498986 - /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.odt/resources/stylesheets/odt-to-forrest-xhtml.xsl
Date Tue, 23 Jan 2007 11:04:22 GMT
Author: cdupoirieux
Date: Tue Jan 23 03:04:17 2007
New Revision: 498986

URL: http://svn.apache.org/viewvc?view=rev&rev=498986
Log:
Add the root path in the picture integration. Otherwise, pictures in sub-folders are not well
managed...

Modified:
    forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.odt/resources/stylesheets/odt-to-forrest-xhtml.xsl

Modified: forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.odt/resources/stylesheets/odt-to-forrest-xhtml.xsl
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.odt/resources/stylesheets/odt-to-forrest-xhtml.xsl?view=diff&rev=498986&r1=498985&r2=498986
==============================================================================
--- forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.odt/resources/stylesheets/odt-to-forrest-xhtml.xsl
(original)
+++ forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.odt/resources/stylesheets/odt-to-forrest-xhtml.xsl
Tue Jan 23 03:04:17 2007
@@ -42,6 +42,12 @@
       <xsl:with-param name="path" select="$path"/>
     </xsl:call-template>
   </xsl:variable>
+  <!-- Path to site root, eg '../../' -->
+  <xsl:variable name="root">
+    <xsl:call-template name="dotdots">
+      <xsl:with-param name="path" select="$path"/>
+    </xsl:call-template>
+  </xsl:variable>
 
   <xsl:template match="/">
     <xsl:apply-templates select="/odt/content/*"/>
@@ -232,7 +238,7 @@
 			<img src="{$href}" alt="{../@draw:name}" heigth="{../@svg:heigth}" width="{../@svg:width}"/>
 		</xsl:when>
 		<xsl:otherwise>
-			<img src="/{$dirname}openDocumentEmbeddedImages/zip-{$filename}.odt/file-{$href}" alt="{../@draw:name}"
heigth="{../@svg:heigth}" width="{../@svg:width}"/>
+			<img src="./{$root}{$dirname}openDocumentEmbeddedImages/zip-{$filename}.odt/file-{$href}"
alt="{../@draw:name}" heigth="{../@svg:heigth}" width="{../@svg:width}"/>
 		</xsl:otherwise>
 	</xsl:choose>
 </xsl:template>



Mime
View raw message