[l2h] different versions of the tex-file

Ross Moore ross at ics.mq.edu.au
Sun Nov 23 00:08:58 CET 2003


Hello Phil,

On Sat, 22 Nov 2003, Phil Lanch wrote:

> On Fri, Nov 21, 2003 at 08:39:07PM +0100, webmaster at steinam.de wrote:
> > I have the problem, that I want to write a large document (> 300 pages)
> > with pdflatex for different groups of users, say teachers, students, rest of
> > the world
> >
> > With the package comment no problem in pdflatex
> >
> > \begin{teacher} .... \end{teacher}
> > \begin{student} .... \end{student}
> >
> > But I need html-output too !!
> > The problem now is that latex2html doesn't work together with the
> > package comment. When parsing the source, l2h produces for  this

It is supposed to support the comment.sty environment,
with its  \includecomment  and  \excludecomment commands.

If it isn't working for you, would you please provide a minimal
example which shows the failure.

> > environments an image file, that has nothing to do with the original
> > source.

Remember that LaTeX2HTML does *not* read files ending .sty or .cls,
so perhaps the problem is simply that you haven't told LaTeX2HTML
in the preamble of your document that these are special environments
needing conditional treatment.


> >
> > Has anybody had this problem too ? Can't believe that I'am the first one
> > :-)
> >
> > How can this problem be solved or workarounded ?

Support for comment.sty has been part of LaTeX2HTML since 1995 ...


> this sounded familiar, and i found that i've been using an ugly
> workaround for this problem.  it's a filter to pre-process a LaTeX file
> (i.e. it's to be applied to a .tex before latex2html): attached.
>
> for a proper solution: latex2html can process \begin{htmlonly} and
> \begin{latexonly} sections correctly, so i guess it could easily be
> extended to handle comments in general.

 ... these are implemented in  html.sty  precisely via the commands from
comment.sty .

However, the non-local nature of the processing in LaTeX2HTML means that
separate methods are needed in Perl to implement them properly.
Thus you may need to be a bit more careful with how the preamble is setup.

As above, send a minimal example of your coding that is causing
difficulties.


Hope this helps,

	Ross Moore


>
> --
> Phil Lanch                    0xD78D598DA6635CF32AB24593C98994B7D95B33E3
>    http://www.subtle.clara.net/rephrase/ - GnuPG passphrase recovery
>
>   If I knew then what I know now, I would have said 'I don't recall'.
>


More information about the latex2html mailing list