Plugin dita-embed-html-xslfo

Post here questions and problems related to editing and publishing DITA content.
gbv34
Posts: 105
Joined: Thu Jan 20, 2022 12:36 pm

Plugin dita-embed-html-xslfo

Post by gbv34 »

Hello, Radu!
So far, I used your plugin dita-embed-html-xslfo with success until recently, but I wanted to update my OT version. So, I've tried to use the plugin with OT 3.5.4 and 3.7 and it seems it does not work anymore.

I don't have error messages, just the fact that embed HTML like shown in the example is not displayed anymore:

Code: Select all

        <!-- Embed HTML video -->
        <foreign outputclass="html-embed"><![CDATA[
            <iframe width="420" height="315" src="https://www.youtube.com/embed/qepRkQxhTXQ" frameborder="0" allowfullscreen="true">
            </iframe>
            ]]></foreign>
Have you already received feedback from other users on the compatibility of the plugin with more recent OT versions?
------
Gaspard
Radu
Posts: 9438
Joined: Fri Jul 09, 2004 5:18 pm

Re: Plugin dita-embed-html-xslfo

Post by Radu »

Hi,

Oxygen's bundled DITA OT should also come with this plugin included and it works from what I just tested.
But you are probably using a custom DITA OT with this plugin installed in it, right?
https://github.com/oxygenxml/dita-embed-html-xslfo
After you copied the "com.oxygenxml.html.xslfo.embed" folder in the DITA OT "plugins" folder did you run the DITA OT integrator or run from the command line "dita --install"?

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
gbv34
Posts: 105
Joined: Thu Jan 20, 2022 12:36 pm

Re: Plugin dita-embed-html-xslfo

Post by gbv34 »

Hi Radu,
Thanks for your answer. That's true, I use a custom OT but I also used the integrator to make sure the plugin is correctly integrated.
Surprisingly, it works with the OT 3..3.4 whereas the 3.5.4 and 3.7 don't display embed HTML.
------
Gaspard
Radu
Posts: 9438
Joined: Fri Jul 09, 2004 5:18 pm

Re: Plugin dita-embed-html-xslfo

Post by Radu »

Hi Gaspard,

Here's what I did on my side:
1) Download DITA OT 3.7.4: https://github.com/dita-ot/dita-ot/releases/tag/3.7.4
2) Download the plugin: https://github.com/oxygenxml/dita-embed-html-xslfo
3) Copy the folder "com.oxygenxml.html.xslfo.embed" to the "DITA OT/plugins" folder
4) Run "bin/dita --install" in the terminal/console in the DITA OT folder.
5) Run an HTML5 transformation on a DITA Map containing a topic which looks like this:

Code: Select all

<!DOCTYPE topic PUBLIC "-//OASIS//DTD DITA Topic//EN" "topic.dtd">
<topic id="introduction">
	<title>Introduction</title>
	<body>
		 <!-- Embed HTML video -->
        <foreign outputclass="html-embed"><![CDATA[
            <iframe width="420" height="315" src="https://www.youtube.com/embed/qepRkQxhTXQ" frameborder="0" allowfullscreen="true">
            </iframe>
            ]]></foreign>
	</body>
</topic>

Code: Select all

 ./dita -i /Users/../flowers.ditamap -o /Users/../flowers/out/ -f html5
6) The resulting HTML for my topic contains the embedded video which can be played in the web browser.

Maybe you can try the same steps as I did, it might be possible that you have another custom plugin which interferes with this one. Also the plugin folder "com.oxygenxml.html.xslfo.embed" is the one which contains a "plugin.xml" inside, so make sure you did not copy the entire "dita-embed-html-xslfo-master" folder instead to the "plugins" folder.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
gbv34
Posts: 105
Joined: Thu Jan 20, 2022 12:36 pm

Re: Plugin dita-embed-html-xslfo

Post by gbv34 »

Hi Radu,
That was absolutely silly of me.
I didn't check inside the plugin folder and... Indeed, the plugin itself was inside a subfolder :roll:
Everything works perfectly now. Sorry about the noise.
------
Gaspard
Post Reply