simple Body Onload question

Discussion in 'Javascript' started by Raphael Gluck, Oct 24, 2003.

  1. Hi Everyone
    Just a simple question
    If i have more than one Javascript in the head tag, and both have a body
    Onload how do i write the opening body tag?
    do i enter two Onloads? This didnt work for me.
    <body onLoad=" MM_preloadImages(etc...)" onload="runSlideShow()">

    Can i have one onload call both?

    Please help me

    Raphael
     
    Raphael Gluck, Oct 24, 2003
    #1
    1. Advertising

  2. is this the solution

    <body onLoad=" MM_preloadImages('etc...'); runSlideShow()">

    Raphael
     
    Raphael Gluck, Oct 24, 2003
    #2
    1. Advertising

  3. Raphael Gluck

    kaeli Guest

    In article <bnb2kd$ijf$>,
    enlightened us with...
    > is this the solution
    >
    > <body onLoad=" MM_preloadImages('etc...'); runSlideShow()">
    >


    Yup. :)


    -------------------------------------------------
    ~kaeli~
    Jesus saves, Allah protects, and Cthulhu
    thinks you'd make a nice sandwich.
    http://www.ipwebdesign.net/wildAtHeart
    http://www.ipwebdesign.net/kaelisSpace
    -------------------------------------------------
     
    kaeli, Oct 24, 2003
    #3
  4. While the city slept, Raphael Gluck <> feverishly typed:

    > is this the solution
    >
    > <body onLoad=" MM_preloadImages('etc...'); runSlideShow()">


    That's one. You can also make a new function that runs all your onload
    functions and call that from onload. This is more useful if you have quite a
    few functions to start (less messy). For example...

    In your script block in the head

    function start()
    {
    MM_preloadimages('etc...');
    runSlideShow();
    }

    and in your body tag

    <body onload="start()">

    .... Hope that helps,
    Nige

    --
    Nigel Moss.

    Email address is not valid. . Take the dog out!
    http://www.nigenet.org.uk | Boycott E$$O!! http://www.stopesso.com
    In the land of the blind, the one-eyed man is very, very busy!
     
    nice.guy.nige, Oct 26, 2003
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Fabio R.
    Replies:
    0
    Views:
    821
    Fabio R.
    Mar 25, 2005
  2. UJ
    Replies:
    4
    Views:
    9,688
    =?Utf-8?B?U3JlZWppdGggUmFt?=
    Jul 19, 2005
  3. David Otton

    window.onload and body.onload differences

    David Otton, Nov 4, 2004, in forum: Javascript
    Replies:
    2
    Views:
    587
    Martin Honnen
    Nov 4, 2004
  4. Replies:
    5
    Views:
    286
    Thomas 'PointedEars' Lahn
    May 15, 2005
  5. marco

    onload -->* no onload

    marco, Jun 22, 2006, in forum: Javascript
    Replies:
    7
    Views:
    217
    marco
    Jun 24, 2006
Loading...

Share This Page