Page 1 of 1

How to convert Custom Docbook Topic to DITA

Posted: Thu Dec 06, 2018 3:29 pm
by gopinathselvamin
Hi,

We have thousands of xml in Docbook and uses custom DTD files as shown below.
The second line in my docbook xml is as shown below
I am using Oxygen XML developer to convert these topics to DITA.
How to configure Oxygen XML to transform these custom docbook topics to DITA? Please help me with detailed steps.

<!DOCTYPE GS_Instruction PUBLIC "-//GS//DTD GS_Instruction element definition ver. 1.0//EN" "GS_Instruction.dtd">

Re: How to convert Custom Docbook Topic to DITA

Posted: Thu Dec 06, 2018 3:37 pm
by Radu
Hi,

if you open a standard Docbook file in Oxygen (for example the one in "OXYGEN_INSTALL_DIR\samples\docbook\v5\sample.xml" and click the "Configure Transformation Scenarios" dialog, there is a predefined transformation scenario there called DocBook to DITA. Maybe you can duplicate that transformation scenario and then use it also for your Docbook-like XML documents.
If you want to batch apply a transformation scenario, you can right click a folder containing the XML files in the Oxygen Project view and then choose "Transform with" and choose the transformation scenario to use.

Regards,
Radu

Re: How to convert Custom Docbook Topic to DITA

Posted: Thu Dec 06, 2018 4:08 pm
by gopinathselvamin
Hi,

I tried those steps, the output Dita files doesn't have any contents.
Hope I explained my problem in a way that was understandable by you.
How to convert a custom docbook xml which is based on a custom dtd file into DITA?

Thanks,
Gopi

Re: How to convert Custom Docbook Topic to DITA

Posted: Thu Dec 06, 2018 4:22 pm
by Radu
Hi Gopi,

You will probably need to look at the XSLT stylesheet used for Docbook to DITA conversion:

OXYGEN_INSTALL_DIR\frameworks\docbook\xsl\dbdita\db2dita\docbook2dita.xsl

and make changes to it so that it can also process your custom element names.

Regards,
Radu