is there any call before 'body onload'?

Discussion in 'Javascript' started by Ask Josephsen, Aug 30, 2004.

  1. Hi NG

    Is it possible to make a javascript call before "<body onload='...'>"?

    What I'm doing is a preview of numerous images in an iframe and I want to
    resize the iframe to match each picture. Normally I'd use the 'onload' (on
    the src-page holding the image in the iframe) attrubute, but it's not called
    until the picture has finished loading. I'd like to resize the iframe before
    (or at the same time) the image starts loading.

    Any ideas??


    Med Venlig Hilsen

    Ask Josephsen
     
    Ask Josephsen, Aug 30, 2004
    #1
    1. Advertising

  2. Ask Josephsen

    Evertjan. Guest

    Ask Josephsen wrote on 30 aug 2004 in comp.lang.javascript:

    > Is it possible to make a javascript call before "<body onload='...'>"?


    <script>alert(0)</script>
    <body onload="alert(2)">
    <script>alert(1)</script>

    Elementary, my dear Ask?

    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress,
    but let us keep the discussions in the newsgroup)
     
    Evertjan., Aug 30, 2004
    #2
    1. Advertising

  3. hehe

    what a beauty :eek:)

    thanks

    --

    Med Venlig Hilsen

    Ask Josephsen
    Partner og IT

    web: www.MinReklame.dk

    "Evertjan." <> wrote in message
    news:Xns955590CAF6FF0eejj99@194.109.133.29...
    > Ask Josephsen wrote on 30 aug 2004 in comp.lang.javascript:
    >
    > > Is it possible to make a javascript call before "<body onload='...'>"?

    >
    > <script>alert(0)</script>
    > <body onload="alert(2)">
    > <script>alert(1)</script>
    >
    > Elementary, my dear Ask?
    >
    > --
    > Evertjan.
    > The Netherlands.
    > (Please change the x'es to dots in my emailaddress,
    > but let us keep the discussions in the newsgroup)
    >
     
    Ask Josephsen, Aug 30, 2004
    #3
    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. Daves

    any event before OnLoad?

    Daves, Mar 20, 2005, in forum: ASP .Net
    Replies:
    6
    Views:
    3,466
    Daves
    Mar 21, 2005
  2. Fabio R.
    Replies:
    0
    Views:
    836
    Fabio R.
    Mar 25, 2005
  3. David Otton

    window.onload and body.onload differences

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

    onload -->* no onload

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

Share This Page