Unhandled Perception
From the mind of a developer.

Monday, October 06, 2008

Convert a Word document to HTML (easy and free)

HowTo: Convert a Word document to clean HTML

Ever have a need to convert a Word document to HTML knowing that Word itself produces some of the worst HTML code ever? There is a simple, easy trick to get this done.

  1. Make sure you have a Gmail account
  2. Send the Word document, as an attachment, to your Gmail account
  3. Sign in to Gmail and view the email with the attachment
  4. Click the 'View as HTML' link at the bottom of the email
  5. With the page opened, 'View source' from your browser
  6. Copy the code
That's all there is to it. Google produces some pretty clean HTML from a Word document. It may have to be updated to XHTML 1.0 specifications (Google uses some deprecated tags)

I had a pretty complex tabled document with lots of text styles and it did a very good job.

Labels: , ,

5 Comments:

  • Buddy,

    you made my Day.

    Awesome!

    That is far more better then the Output Word Produces and/or Dreamweaver.

    Guys, if you ever need to convert Word Documents to HTML, do it with Google and this Tipp.

    Thanks, again.

    Tom

    By Anonymous Tom, at 2:47 PM EST  

  • thanks - muchos appreciatos

    By Anonymous Anonymous, at 8:08 AM EST  

  • hey,

    first thanks for the tip. but it only took the header of my attachment.
    the rest didn't show up. any thoughts?

    By Blogger Alex, at 6:43 AM EST  

  • I have never seen that. Google is good at converting the entire document. The reason is they are trying to keep you inside of Google when viewing the document so its in their best interest to convert the whole document.

    By Blogger Veign, at 10:19 AM EST  

  • Good for text only. Images are not seen.

    By Blogger Basdeo, at 8:02 PM EST  

Post a Comment

Links to this post:

Create a Link

<< Home