<shame>Wauw, completely wrong, </shame>

The parents init function is not called from the iframe, the iframe
loaded the same file :P.

I quess there's no need to remove a domready event because it will
only be triggered once.

On 19 jan, 10:44, woomla <[email protected]> wrote:
> Hi,
>
> I have a parent window with an iframe. The parent window has a
> window.addEvent('domready', init); The init function is also called
> when the dom is ready loading the iframe. I use the init to setup some
> dom elements in the parent. This failes if init is called from the
> iframe because logically the elements do not exist in the iframe.
>
> To stop this happening I would like to remove init from domready. At
> the end of init, I calls window.removeEvent('domready', init). But
> still init is called from the iframe.
>
> The function removeEvent looks for custom.onRemove, but that function
> does not exist for 'domready'.
>
> Hence my question, how to remove a domready event? Or how can I
> prevent the iframe from calling it?
>
> Thanks, W.

Reply via email to