SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Zealot
    Join Date
    Mar 2005
    Posts
    113
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    onload alternative?

    I'm using a template and can only insert codes between the body tags. I need to use "onload" to call up the javascript function. Since I can't put it inisde the body tag, is there any alternative to use this function between the body tags?

    Thanks,

    jace

  2. #2
    bronze trophy
    Join Date
    Dec 2004
    Location
    Sweden
    Posts
    2,670
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You can use window.onload:
    HTML Code:
    <script type="text/javascript">
     window.onload = function() {
       doThis();
       doThat();
     }
    </script>
    Simon Pieters

  3. #3
    SitePoint Zealot
    Join Date
    Mar 2005
    Posts
    113
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Great! It worked like a charm!

    Much appreciated!

    jace


Bookmarks

Posting Permissions

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