Path: csiph.com!weretis.net!feeder4.news.weretis.net!feeder5.news.weretis.net!news.solani.org!.POSTED!not-for-mail From: Thomas 'PointedEars' Lahn Newsgroups: comp.lang.javascript Subject: Re: iframe function Date: Mon, 24 Oct 2016 04:26:11 +0100 Organization: PointedEars Software (PES) Lines: 33 Message-ID: <1766631.oMNUckLgyt@PointedEars.de> References: Reply-To: Thomas 'PointedEars' Lahn Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit X-Trace: solani.org 1477279572 6090 eJwFwYEBwDAEBMCVNN5jnBL2HyF3pvzYDhpha4vwm8mtbQZcBGfknhQjNTibAvyazQmrrgcIZhCP (24 Oct 2016 03:26:12 GMT) X-Complaints-To: abuse@news.solani.org NNTP-Posting-Date: Mon, 24 Oct 2016 03:26:12 +0000 (UTC) User-Agent: KNode/4.14.2 X-NNTP-Posting-Host: eJwFwYENwDAIA7CXQCRBOael7P8TZrOUmoYo8ONXked5XpoVyoEOd6PcrcktLydQ24Jxr38MKBB3 X-User-ID: eJwNy8EBwCAIA8CVREOC46jA/iO09z9fND6BTnh7611TpFB0DNnKWTtjeMV4QeCQReZfOqXTFy1iz1vT2/gBQGAVJg== Cancel-Lock: sha1:hAbcQS2Wgkww86avIfl3DJJzlQg= Xref: csiph.com comp.lang.javascript:31600 Andrew Poulos wrote: > If a page contains an IFRAME and the IFRAME has some JavaScript that > looks like: > > var aVar = "hello"; > > var myFunc = function() { > return (aVar == "hello"); > }; > > window.parent.myFunc = myFunc; > > and in the parent window I call myFunc() is the aVar value the one in > the IFRAME or the one in the parent window? Yes. > I've got a, for me, complex elearning course that uses an IFRAME for > some things and the parent window for others and I'm trying to debug > some errors but I don't really understand what the "correct" answer > should be. -- PointedEars FAQ: | SVN: Twitter: @PointedEars2 | ES Matrix: Please do not cc me. / Bitte keine Kopien per E-Mail.