Figured it out.
What I needed was this thing called a hook. (I'm still learning)
a function defined in popBox.js (OnAfterLoad, that Does Nothing) that is
called at the end of onload.
This allowed us to redefine the function on the calling page. (after it
is first defined but before it is called)
So that when the onload function ran the layer would be shown or not
shown depending if OnAfterLoad is defined on the calling page.
It seems klunky but I'll take what works.
--
from the desk of Whifflebat
aka - Joshua O'Connor-Rose
-All is Good
Doug Melvin wrote:
>
> 1) I believe the is an onafterload event (i could be wrog)
> 2) you should put any such code into DynAPI.OnLoad()
> ----- Original Message -----
> From: "Joshua O'Connor-Rose" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Tuesday, March 20, 2001 10:06 AM
> Subject: [Dynapi-Help] handling onload functions
>
> > I've been using the API for 6 months . . . love it.
> >
> > moving on.
> >
> > I'm having trouble calling a function (makeLayer) that is called when
> > the page loads
> > and references layers also created when the page loads. The trouble is
> > the function is invoked on the page before the
> > layers exist.
> >
> > I tried several varieties of "onload" but none of them have worked so
> > far. (I believe because onload is called by the API
> > before I call the function.)
> >
> > Is there a way I can call a function when the page is done loading.
> > Or ensure that the layers are created before the function call (I
> > thought they were)
> >
> >
> >
> > --
> >
> > from the desk of Whifflebat
> > aka - Joshua O'Connor-Rose
> >
> > -All is Good
> >
> > _______________________________________________
> > Dynapi-Help mailing list
> > [EMAIL PROTECTED]
> > http://lists.sourceforge.net/lists/listinfo/dynapi-help
>
> _______________________________________________
> Dynapi-Help mailing list
> [EMAIL PROTECTED]
> http://lists.sourceforge.net/lists/listinfo/dynapi-help
_______________________________________________
Dynapi-Help mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/dynapi-help