With this method, users can allow specific videos to play automatically.
- Download a version of DITA-OT up to 3.7.
- Download the
dita-media-support
plugin. - Extract the DITA-OT archive.
- Extract the plugin, open the
dita-media-support-master
folder, and copy thecom.oxygenxml.media
folder. - Paste the
com.oxygenxml.media
folder into theplugins
directory of the DITA-OT folder. -
Open the
plugin.xml
file, and add comment tags (<!-- -->
) at the beginning and end of the following lines:<feature extension="com.oxygenxml.pdf.css.xsl.merged2html5" value="xhtmlMedia.xsl" type="file"/> <feature extension="com.oxygenxml.pdf.css.xsl.merged2html5.parameters" value="insertParameters.xml" type="file"/>
Adding comment tags around the lines disables them.
-
Open a terminal window.
-
From the
bin
subfolder, run the following command:./dita install
The output of this command should be:
Added com.oxygenxml.media
-
Create an archive containing the DITA-OT folder.
- Upload this new DITA-OT archive.
-
Publish DITA content containing a video.
For example:
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE topic PUBLIC "-//OASIS//DTD DITA Topic//EN" "topic.dtd"> <topic id="example"> <title>Example topic</title> <body> <object data="videos/MyVideo.mp4" outputclass="video" width="560px" height="315px"> <param name="allowfullscreen" value="true"/> </object> </body> </topic>
Do not use <param name="autoplay" value="false"/>
. It does not disable video autoplay.