Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 11 of 11
  1. #1
    Regular Coder
    Join Date
    Feb 2007
    Location
    London
    Posts
    225
    Thanks
    16
    Thanked 2 Times in 2 Posts

    To 'table' or not to 'table'?

    I'm just about to start the horrific task of converting hundreds of Word docs to nicely-formatted html, and was wondering, before beginning, if anyone had any tips or suggestions regarding how to go about it.

    All of the pages are riddled with tabulated data as illustrated in this jpg:



    Rendering such a layout with tables and CSS won't be a problem, but typing all those nasty <td>'s is gonna be a pain.

    I'm not quite sure what answer I'm expecting, but I thought I'd run the project by you guys first in the hope that there might be some other(quicker?) way. (Or some obvious alternative that I simply don't know about!)

    Any thoughts?
    :-)
    Thanks

  • #2
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    Do you have a document you can attach? I'm curious as to what Dreamweaver will do with the html output from Microsoft.
    ||||If you are getting paid to do a job, don't ask for help on it!||||

  • Users who have thanked _Aerospace_Eng_ for this post:

    cfructose (09-14-2007)

  • #3
    Regular Coder
    Join Date
    Feb 2007
    Location
    London
    Posts
    225
    Thanks
    16
    Thanked 2 Times in 2 Posts
    Voilà
    Attached Files Attached Files

  • #4
    Master Coder felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, Australia
    Posts
    6,627
    Thanks
    0
    Thanked 648 Times in 638 Posts
    I havea table generator at http://javascript.about.com/library/bltablegen.htm that can create all the necessary HTML tags for whatever sized table you want so that all you have to do is plug in the content. That would save you typing in all the tags. Don't know if copy/pasting the content will be quicker though.
    Stephen
    Learn Modern JavaScript - http://javascriptexample.net/
    Helping others to solve their computer problem at http://www.felgall.com/

    Don't forget to start your JavaScript code with "use strict"; which makes it easier to find errors in your code.

  • #5
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    Hmm Dreamweaver doesn't do to good of a job with it. This is the output of the "Clean Word HTML" option in Dreamweaver CS3 after saving the Word Document as an html file.
    Attached Files Attached Files
    ||||If you are getting paid to do a job, don't ask for help on it!||||

  • #6
    Regular Coder
    Join Date
    Feb 2007
    Location
    London
    Posts
    225
    Thanks
    16
    Thanked 2 Times in 2 Posts
    Thanks felgall - that generator will be useful.

    Aerospace - I never owned dreamweaver: now I know why! :-) 'Interesting' results. Thanks for trying. (By the way, if you really want a laugh, try using Microsoft Word to convert it to html...)

  • #7
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    I did. I used word to convert it to html and then used Dreamweaver to clean up the Word HTML. I say it did a decent job but it doesn't understand semantics. Dreamweaver is a tool. You have to learn how to use it for it to be any use to you.
    ||||If you are getting paid to do a job, don't ask for help on it!||||

  • #8
    Regular Coder Actinia's Avatar
    Join Date
    Feb 2007
    Location
    Essex, UK
    Posts
    250
    Thanks
    1
    Thanked 23 Times in 22 Posts
    I have a PHP script that takes the output of Word XP 'save as HTML' and strips it bare. By default it inserts the University of East London style file , but this can easily be replaced.

    It usually preserves tables OK.

    John

  • #9
    Regular Coder
    Join Date
    Feb 2007
    Location
    London
    Posts
    225
    Thanks
    16
    Thanked 2 Times in 2 Posts
    Hi, JohnRostron - sounds like that script would save my life. Any chance of emailing it to: codingforums AT mathesonbayley DOT com please? :-)

  • #10
    Regular Coder Actinia's Avatar
    Join Date
    Feb 2007
    Location
    Essex, UK
    Posts
    250
    Thanks
    1
    Thanked 23 Times in 22 Posts
    The script is installed at the link given and can be used from there. If you did not get the link, here it is again.

    http://php.uel.ac.uk/XPFilter.php

    If you really need the original script, I can email it to you.

    BtW, When I said 'bare' I meant bare HTML, with all, scripting and styling removed.

    John

  • #11
    Regular Coder
    Join Date
    Feb 2007
    Location
    London
    Posts
    225
    Thanks
    16
    Thanked 2 Times in 2 Posts
    Sorry, I didn't notice the link before.

    Thanks a lot, John


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •