1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2002
    Rep Power

    Unhappy Adding "header" & "footer" to html files?

    I have a lot of html files which are saved from *.doc using Microsoft Word. Then I need to add uniform "header" and "footer" to all of them, I mean, do it in a batch. A friend told me that he did it with AppleScript on Mac. He made separate *.txt files for the "header" and "footer" and then use script to add them onto the files. Is there any tool for PC to do that?
    Many thanks.
  2. #2
  3. No Profile Picture
    El Guapo
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2001
    You have moved into a dark place. It is pitch black. You are likely to be eaten by a grue.
    Rep Power
    Not really an XML question, but okay...

    The best way to add a header or a footer would be with some sort of server-side include. You could use a text-editor like UltraEdit or a hardcore WYSIWYG HTML editor like Dreamweaver to prepend and append your headers and footers, but you're going to run into problems when you need to change anything in them.

    The best way to handle this is to make *one* header file and *one* footer file and then include them in your pages using SSI or PHP (or whatever scripting language is in fashion these days).

    What's your server environment like?

    -- Jough
    See my PHP in action:
    Poetry Archives

IMN logo majestic logo threadwatch logo seochat tools logo