[tex4ht] add metadata to docbook

Radhakrishnan CV cvr at river-valley.org
Wed Apr 3 05:24:15 CEST 2013

On Tue, Apr 2, 2013 at 8:18 PM, Matteo Gamboz <gamboz at medialab.sissa.it>wrote:

> Hi all,
>   I'm trying to add some metadata to a docbook xml.
> I'd like to map some simple macros like "\keywords{k}" to xml fragments
> such as:
> <info>
> <keyworsed>
> <keyword>k</keyword
> </keyworsed>
> </info>

I would recommend to keep a custom definition for keywords kind of things
and hence \maketitle too in your custom *.cfg since each document class has
its own front matter setup. My bbb.cfg would look like:

%----------- begin bbb.cfg -----------








%---------------- end --------------

\printkeywords will parse your comma separated keyword list and tag each
keyword individually.

Your source document will look like:

%-----------------begin x.tex ------------






%---------------- end ---------------

The output generated by  the command, htlatex x bbb, will look like:

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
<html xmlns="http://www.w3.org/1999/xhtml">
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"
    <meta name="generator" content="TeX4ht (http://www.tug.org/tex4ht/)" />
    <meta name="originator" content="TeX4ht (http://www.tug.org/tex4ht/)" />
    <!-- html,xhtml -->
    <meta name="src" content="x.tex" />
    <meta name="date" content="2013-04-03 08:26:00" />
    <link rel="stylesheet" type="text/css" href="x.css" />
    <!--l. 11-->
    <p class="indent">hello</p>

Best regards
River Valley<https://maps.google.com/maps?q=River%20Valley,%20Thiruvananthapuram%20Neyyardam%20Road,%20Kerala,%20India&vector=1>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/tex4ht/attachments/20130403/6be6f6e5/attachment.html>

More information about the tex4ht mailing list