Page 1 of 1

XML Database drop DOCTYPE in DITA maps

Posted: Fri Jan 22, 2016 5:28 pm
by stefanpopovic
We are using oXygen Author for technical documents and are moving towards native XML database to store and distribute content. I'm toying with both BaseX and eXist and they both display this rather unfortunate behavior with regards to DITA Maps files: the DOCTYPE tag is dropped after the file is uploaded to the database.

When I try to open the .ditamap file in the oXygen Author DITA Maps Manager, the file doesn't open and I get the following error:
"Could not determine if the opened file is a DITA map or topic.
If it is, please make sure the DITA framework component has been installed."

Opening the same file in the editor works, but the DOCTYPE tag is absent.

Do you have any recommendation to avoid this problem?

Thanks,
Stefan

Re: XML Database drop DOCTYPE in DITA maps

Posted: Fri Jan 22, 2016 5:49 pm
by Radu
Hi Stefan,

I remember from an older forum discussion that Exist has support to preserve the DOCTYPE:

topic9204.html

Not sure about BaseX, you should probably try to find a BaseX users list and ask there. Maybe you can also update this post if you find anything.

Regards,
Radu

Re: XML Database drop DOCTYPE in DITA maps

Posted: Fri Jan 22, 2016 6:10 pm
by stefanpopovic
Thank you Radu.

I tried to add the PI directive as per the forum thread you mentioned and it seems to work. I'd have to add this PI to all dita files am I right?

I'll try to find out if there's a similar solution for BaseX. If I find out, I'll post it here for sure.

Thanks again,
Stefan

Re: XML Database drop DOCTYPE in DITA maps

Posted: Fri Jan 22, 2016 6:25 pm
by Radu
Hi Stefan,

About this question:
I'd have to add this PI to all dita files am I right?
I'm not sure, maybe Exist has an alternative server-side setting, you could also try to ask around on the Exist users list.

Regards,
Radu

Re: XML Database drop DOCTYPE in DITA maps

Posted: Mon Jan 25, 2016 4:13 pm
by george
Another solution may be to use Relax NG instead of DTDs for DITA. If you run the transformations from within oXygen they should already work. Otherwise you will need two libraries in the DITA-OT classpath (Jing and DITA-NG) to get this working from the command line. For associating RelaxNG schemas with the documents we use xml-model processing instructions and hopefully these will not be removed by eXist and/or baseX.

Best Regards,
George

Re: XML Database drop DOCTYPE in DITA maps

Posted: Mon Jan 25, 2016 5:50 pm
by stefanpopovic
Thank you for the suggestion George. I will investigate if this is an option for us.

Regarding BaseX, there really isn't any better solution: https://mailman.uni-konstanz.de/piperma ... 10128.html

They also mentioned Argon Author: http://argon-author.com/. Does anybody have any info about this solution? There's only a public Beta for now.

Best regards,
Stefan

Re: XML Database drop DOCTYPE in DITA maps

Posted: Tue Jan 26, 2016 10:55 am
by george
Axxepta presented the Argon Author at Tekom last year!
The Argon Author is a product that includes the oXygen SDK, more specifically the oXygen Author Component from the SDK, to provide XML authoring support. It connects to BaseX as repository, and probably it also handles issues like preserving DOCTYPE declarations, etc.

Best Regards,
George