title: Add event handler for body.onload by Javascript within <body> part
body: <p>We want to include a maps from Google Maps API in our document. The documentation tells to initialize the map with a function called by the <code>onload()</code> event of the body.</p>
  <p>The ordinary way to call:</p>
  <pre><code>&lt;body onload=&quot;initialize_map();&quot;&gt;
  </code></pre>
  <p>This doesn't work out for us because we're using <code>Template::Toolkit</code> and the <code>&lt;body&gt;</code> tag is already included in our wrapper. In short: The <code>&lt;body&gt;</code> tag is already printed when our Javascript code starts running.</p>
  <p>I tried something like this but it does only work for <code>onclick</code>, not <code>onload</code>. I guess that's because the Javascript code is beneath the <code>&lt;body&gt;</code> tag itself.</p>
  <pre><code>var body = document.getElementsByTagName(&quot;body&quot;)[0];
  
  body.addEventListener(&quot;load&quot;, init(), false);
  
  function init() {
          alert(&quot;it works!&quot;);
  };
  </code></pre>
  <p>Any help how to fire up a Google Maps map appreciated!</p>