Getting TOhtml to generate valid XHTML

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Getting TOhtml to generate valid XHTML

Goli, Rajesh (Rajesh)
Hi,

I tried using the 'tohtml'/'2html' plugin that comes along with vim. I
noticed that it uses stuff like 'font', 'text' and 'bgcolor' which are
deprecated in XHTML. Has anyone modified the script to generate valid XHTML
that validates in w3c's html validator already?

Thanks,

Rajesh
------------------
www.rajeshgoli.com
Reply | Threaded
Open this post in threaded view
|

Re: Getting TOhtml to generate valid XHTML

A.J.Mechelynck
----- Original Message -----
From: "Goli, Rajesh (Rajesh)" <[hidden email]>
To: <[hidden email]>
Sent: Thursday, August 11, 2005 9:14 AM
Subject: Getting TOhtml to generate valid XHTML


> Hi,
>
> I tried using the 'tohtml'/'2html' plugin that comes along with vim. I
> noticed that it uses stuff like 'font', 'text' and 'bgcolor' which are
> deprecated in XHTML. Has anyone modified the script to generate valid
> XHTML
> that validates in w3c's html validator already?
>
> Thanks,
>
> Rajesh
> ------------------
> www.rajeshgoli.com
>
>

From ":help :TOhtml":

By default, HTML optimized for old browsers is generated.  If you prefer
using
cascading style sheets (CSS1) for the attributes (resulting in considerably
shorter and valid HTML 4 file), use: >
   :let html_use_css = 1

There are several other settings, you may want to check them too.

Best regards,
Tony.


Reply | Threaded
Open this post in threaded view
|

Re: Getting TOhtml to generate valid XHTML

Bram Moolenaar
In reply to this post by Goli, Rajesh (Rajesh)

Rajesh Goli wrote:

> I tried using the 'tohtml'/'2html' plugin that comes along with vim. I
> noticed that it uses stuff like 'font', 'text' and 'bgcolor' which are
> deprecated in XHTML. Has anyone modified the script to generate valid XHTML
> that validates in w3c's html validator already?

    :let use_xhtml = 1

I don't remember in which version this was added...

--
I'm not familiar with this proof, but I'm aware of a significant
following of toddlers who believe that peanut butter is the solution
to all of life's problems... -- Tim Hammerquist

 /// Bram Moolenaar -- [hidden email] -- http://www.Moolenaar.net   \\\
///        Sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\              Project leader for A-A-P -- http://www.A-A-P.org        ///
 \\\     Buy LOTR 3 and help AIDS victims -- http://ICCF.nl/lotr.html   ///