« semantic web, ambient findability | Main | kurzweil »

January 12, 2006

Experimenting with Word

We get lots of questions about using Word to create web pages. Obviously, we don't recommend this method. Word tries very hard to translate it's own rich formatting language into a language, HTML, that was never designed to be a formatting language. The resulting file is filled with code that can cause problems when one tries to edit the resulting HTML file.

Here are several examples of files that have been created in Word, then translated into HTML files. To see exactly how Word has translated the file, look at it using View: Page Source:


Original Word document

Word document saved as a Web Page
Word document saved as a filtered web page
Word document, contents copy and pasted into Composer, then saved
Word document, save as filtered web page, then, while still in Word, contents copied and pasted into Composer

When you copy and paste text from Word directly into Moveable Type's entry area (this area) you lose all formatting except for line breaks.

If you save a Word file as a filtered web page, open it in Composer (a simple HTML editor), and copy and paste the source code into a blog entry, here is the result:



content="text/html; charset=windows-1252">

Sample Document




Sample Document


 


This is a document to see how translations from
Word to
other programs alter this original document.


 


Here is a paragraph with a first line indent. It
is indented
using the Format: Paragraph: First Line Indent to .25 inches.


 


Here comes a bulleted list:



  • Item one


    • Sub-item one

    • Sub-item two

    • Sub-item three


      • Sub-sub-item one

      • Sub-sub-item two

      • Sub-sub-item two


    • Sub-item four

    • Sub-item five


  • Item two

  • Item three


 


Here is a table:


style="border: medium none ; border-collapse: collapse;" border="1"
cellpadding="0" cellspacing="0">


style="border: 1pt solid windowtext; padding: 0in 5.4pt; width: 2.05in;"
valign="top" width="246">

Cell a1



style="border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 1pt 1pt 1pt medium; padding: 0in 5.4pt; width: 2.05in;"
valign="top" width="246">

Cell b1



style="border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 1pt 1pt 1pt medium; padding: 0in 5.4pt; width: 2.05in;"
valign="top" width="246">

Cell c1





style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 2.05in;"
valign="top" width="246">

Cell a2



style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1pt 1pt medium; padding: 0in 5.4pt; width: 2.05in;"
valign="top" width="246">

Cell b2



style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1pt 1pt medium; padding: 0in 5.4pt; width: 2.05in;"
valign="top" width="246">

Cell c2






 


 


And another table with some interesting formatting
including
different borders, cell width set to content size, and some joined
cells.


 


style="border: medium none ; width: 473.4pt; border-collapse: collapse;"
border="1" cellpadding="0" cellspacing="0" width="789">





style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1pt 1pt; padding: 0in 5.4pt;"
valign="top">

Cell a1: a lengthy bit of text



style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1pt 1pt medium; padding: 0in 5.4pt;"
valign="top">

Cell b1



style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1pt 1pt medium; padding: 0in 5.4pt; width: 236.15pt;"
valign="top" width="394">

Cell
c1: right aligned contents





style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1pt 1pt; padding: 0in 5.4pt;"
valign="top">

Cell a2



style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1pt 1pt medium; padding: 0in 5.4pt;"
valign="top">

Cell b2



style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1pt 1pt medium; padding: 0in 5.4pt; width: 236.15pt;"
valign="top" width="394">

Cell
c2 right aligned contents





style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1pt 1pt; padding: 0in 5.4pt;"
valign="top">

Cell a3



style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1pt 1pt medium; padding: 0in 5.4pt;"
valign="top">

Cell b3



style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1pt 1pt medium; padding: 0in 5.4pt; width: 236.15pt;"
valign="top" width="394">

Cell
c3 right aligned contents





style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1pt 1pt; padding: 0in 5.4pt;"
valign="top">

Cell a4: this cell has different borders



style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1pt 1pt medium; padding: 0in 5.4pt;"
valign="top">

Cell b4



style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1pt 1pt medium; padding: 0in 5.4pt; width: 236.15pt;"
valign="top" width="394">

Cell
c4 right aligned contents





style="border: 1pt solid windowtext; padding: 0in 5.4pt; width: 473.4pt;"
valign="top" width="789">

Three Joined Cells



 


 


This paragraph has some italicized text,
some bolded
text
, and some underlined text as well as text in style="font-size: 14pt; font-family: Batang;">several style="font-family: "Arial Black";">different style="font-size: 16pt; font-family: "Courier New";">fonts.


 


How does the translation handle Styles?


 


Here are two styles: style="font-size: 13pt;"> heading 1, double indent with
a 6 point
space above:


 


Heading 1


 


This paragraph has a style applied to it that
indents
the paragraph .5 inches on either side and adds a 6 point space above
the
paragraph.




Posted by hag at January 12, 2006 9:53 AM

Comments

Post a comment

Thanks for signing in, . Now you can comment. (sign out)

(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)


Remember me?