I output HTML 5 from DITA-OT. Development of WebHelp.

199 views
Skip to first unread message

ar...@antenna.co.jp

unread,
Aug 7, 2017, 9:22:01 PM8/7/17
to DITA-OT Users

Hello Everyone.


We are studying outputting HTML 5 from DITA - OT and building WebHelp.

There is a problem with closing tags and XSLT can not read it simply.


When outputting with HTML 5 from DITA - OT, what kind of means is available for XSLT development method?

Or what are the means of development other than XSLT?


Best Regards,

T.Aaruga


t.aruga

unread,
Aug 8, 2017, 10:46:35 PM8/8/17
to DITA-OT Users
When HTML 5 is output from DITA - OT, the tag may not be closed.
It is necessary to decorate the results output from DITA - OT when developing WebHelp, but I think that when developing it with XML (XSLT), that will be a problem.

tag is not closed sample. HTML 5 is output from DITA - OT

<!DOCTYPE html
  SYSTEM "about:legacy-compat">
<html lang="en">
   <head>
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <!-- !!!!! The tag is not closed -->
      <meta charset="UTF-8">
      <meta name="copyright" content="(C) Copyright 2017">
      <meta name="DC.rights.owner" content="(C) Copyright 2017">
      <meta name="DC.Type" content="map">
      <meta name="DC.Format" content="XHTML">
      <link rel="stylesheet" type="text/css" href="commonltr.css">
      <title>Growing Flowers</title>
   </head>
   <body>


2017年8月8日火曜日 10時22分01秒 UTC+9 t.aruga:

Jarno Elovirta

unread,
Aug 9, 2017, 1:15:42 AM8/9/17
to t.aruga, DITA-OT Users
Hi Aruga,

The output from DITA-OT is HTML5 and it’s not XML. That is why the tag is not closed.

If you want to get XHTML5 output that is XML, you need to change <xsl:output> to use method=“xhtml".

Cheers,

Jarno


--
You received this message because you are subscribed to the Google Groups "DITA-OT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dita-ot-user...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

t.aruga

unread,
Aug 9, 2017, 4:04:15 AM8/9/17
to DITA-OT Users, ar...@antenna.co.jp
Dear Jarno :)

Thank you for your reply.

I need to change <xsl:output> to use method=“xhtml".
Are those files those?

[DITA-OT]\plugins\org.dita.html5\xsl\
dita2html5.xsl
map2html5-cover.xsl

Best Regards,

t.aruga



2017年8月9日水曜日 14時15分42秒 UTC+9 Jarno Elovirta:

Jarno Elovirta

unread,
Aug 10, 2017, 4:37:23 AM8/10/17
to t.aruga, DITA-OT Users
Hi Aruga,

You should not modify DITA-OT files. Instead, you should create a plugin that extends HTML5 transtype. See http://www.dita-ot.org/2.5/dev_ref/plugin-creating.html for documentation. 

- Create a custom transtype, for example aruga-html5 
- Add shell XSLT for this new transtype
- In shell XSLT <xsl:import> main HTML5 shell XSLT and add <xsl:output method=“xhtml”>.

Cheers,

Jarno

t.aruga

unread,
Aug 14, 2017, 1:22:01 AM8/14/17
to DITA-OT Users, ar...@antenna.co.jp
Hi jarno.

I will try what you taught.
Thank you very much ;)

About the result of outputting HTML 5 or XTHML from DITA-OT
I will try to check other differences of closing tags.

Conversion of HTML5 and XTHML from DITA-OT
Is there a feature of the specification?
Only the surface is fine.

Best Regards,

t.aruga

2017年8月10日木曜日 17時37分23秒 UTC+9 Jarno Elovirta:

Jarno Elovirta

unread,
Aug 14, 2017, 1:24:04 AM8/14/17
to t.aruga, DITA-OT Users
Hi Aruga,

Please see the DITA-OT documentation. That is the only documentation we have. If something is not documented in the developer documentation, you have to read the code.

Cheers,

Jarno

t.aruga

unread,
Aug 14, 2017, 1:30:21 AM8/14/17
to DITA-OT Users, ar...@antenna.co.jp
Hello Jarno.

I will read it.
Thank you very much :)

t.aruga

2017年8月14日月曜日 14時24分04秒 UTC+9 Jarno Elovirta:
Reply all
Reply to author
Forward
Message has been deleted
0 new messages