Changeset 5635


Ignore:
Timestamp:
May 18, 2011, 9:26:37 PM (10 years ago)
Author:
Nicklas Nordborg
Message:

Fixes #1607: Help text generation creates invalid xml

The fix generates the help descriptions with <![CDATA[...]]> sections instead of doing a search-and-replace afterwards for encoding the html tags. This seems to work quite well and the file is a lot more readable than before.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/build.xml

    r5634 r5635  
    13721372          <param name="xsltproc.option.--nonet"  expression="" />
    13731373      </xslt>
    1374 
    1375     <replaceregexp
    1376       file="data/helptexts.xml"
    1377       match="&lt;(?!/?name|/?description|/?helpitem|/?helptexts)(/?([a-z]+)[^>]*)&gt;"
    1378       replace="&amp;lt;\$1&amp;gt;"
    1379       flags="sg"
    1380     />
    13811374  </target>
    13821375 
  • trunk/lib/docbook/preprocess/webclient_helptext.xsl

    r4509 r5635  
    2323  <xsl:import href="../docbook/xsl/html/docbook.xsl" />
    2424  <xsl:param name="admon.style"></xsl:param>
     25  <xsl:param name="chunker.message.nofilename">0</xsl:param>
    2526
    2627  <xsl:output method="xml" doctype-system="helpfile.dtd" indent="yes" encoding="UTF-8" />
     
    2829  <xsl:template match="/">
    2930    <xsl:comment>
    30 "Copyright (C) Authors contributing to this file.
     31Copyright (C) Authors contributing to this file.
    3132
    3233This file is part of BASE - BioArray Software Environment. Available at
     
    3536BASE is free software; you can redistribute it and/or modify it under the terms of the
    3637GNU General Public License as published by the Free Software Foundation; either version
    37 2 of the License, or (at your option) any later version.
     383 of the License, or (at your option) any later version.
    3839
    3940BASE is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
     
    5556          </xsl:element>
    5657          <xsl:element name="description">
    57               <xsl:apply-templates select="*"/>
     58            <xsl:text disable-output-escaping="yes">&lt;![CDATA[</xsl:text>
     59            <xsl:apply-templates select="*"/>
     60            <xsl:text disable-output-escaping="yes">]]&gt;</xsl:text>
    5861          </xsl:element>
    5962        </xsl:element>
Note: See TracChangeset for help on using the changeset viewer.