withFrames equivalent for Feedback

Here should go questions about transforming XML with XSLT and FOP.
manthony
Posts: 22
Joined: Mon Jan 20, 2014 11:44 pm

withFrames equivalent for Feedback

Post by manthony »

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: 4141
Joined: Fri Mar 28, 2003 2:12 pm

Re: withFrames equivalent for Feedback

Post by sorin_ristache »

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
Joined: Mon Jan 20, 2014 11:44 pm

Re: withFrames equivalent for Feedback

Post by manthony »

Thanks that worked.
Post Reply