withFrames equivalent for Feedback

Here should go questions about transforming XML with XSLT and FOP.
manthony
Posts: 22

withFrames equivalent for Feedback

Tue Nov 04, 2014 4:17 am

Hi,

I need to test during the transform to see if the transformation is for Webhelp with Feedback. I can see in the createMainFiles.xl there is a ${withFrame} parameter/variable --- does a similar one exist for Webhelp with Feedback?

Mary
sorin_ristache
Posts: 4144

Re: withFrames equivalent for Feedback

Tue Nov 04, 2014 11:48 am

Hi,

You can test the parameter WEBHELP_PRODUCT_ID in any XSLT stylesheet used in the transformation started by OXYGEN_INSTALL_DIR\frameworks\dita\DITA-OT\plugins\com.oxygenxml.webhelp\xsl\dita\desktop\dita2webhelp.xsl:

Code: Select all

<xsl:if test="$WEBHELP_PRODUCT_ID != ''">


In the createMainFiles.xsl transformation it is not available because the output of that transformation does not depend on the type: WebHelp with feedback or WebHelp without feedback. If you want to do a check for the transformation type also in the createMainFiles.xsl stylesheet you will have to pass a parameter in the file OXYGEN_INSTALL_DIR\frameworks\dita\DITA-OT\plugins\com.oxygenxml.webhelp\build_dita.xml:

Code: Select all

<target name="create-main-files" depends="check-image-file-exist">

  .  .  .

      <xslt processor="trax"
          in="${dita.temp.dir}/${user.input.file}"
          out="${output.dir}/dummy.html"
          style="${args.create.main.files.xsl}"
          force="yes"
          classpathref="dost.class.path">

          .  .  .

          <param name="WEBHELP_PRODUCT_ID" expression="${webhelp.product.id}" if="webhelp.product.id"/>
      </xslt>
</target>


and add the parameter in the file OXYGEN_INSTALL_DIR\frameworks\dita\DITA-OT\plugins\com.oxygenxml.webhelp\xsl\createMainFiles.xsl:

Code: Select all

  <xsl:param name="WEBHELP_PRODUCT_ID" select="''"/>
Regards,
Sorin

<oXygen/> XML Editor Support
manthony
Posts: 22

Re: withFrames equivalent for Feedback

Tue Nov 04, 2014 10:33 pm

Thanks that worked.

Return to “XSLT and FOP”

Who is online

Users browsing this forum: No registered users and 2 guests