How can I append header and footer text through javascript calls

Giganews Newsgroups
Subject: How can I append header and footer text through javascript calls
Posted by:  Patrick Gibbons (fnkler…@hotmail.com)
Date: Mon, 07 Jul 2003

What I would like to do is create header and footer information for my
webpages which are created by calling from a referenced .js page . . . for
example
in Header.js:
<script language="JavaScript">
function CreateHeader
{
  document.writeln("<table>")
  document.writeln("<tr>")
  document.writeln("<td>")
  document.writeln("Stuff")
  document.writeln("</td>")
  document.writeln("</tr>")
  document.writeln("</table>")

}
</script>

in Index.htm:
<body>
  <script type="text/javascript">
    onLoad="CreateHeader()"
  </script>
</body>

Which would give me in this case a Stuff in a one celled table.

Replies