Path: csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!dedibox.gegeweb.org!gegeweb.eu!nntpfeed.proxad.net!proxad.net!feeder2-2.proxad.net!newsfeed.arcor.de!newsspool4.arcor-online.net!news.arcor.de.POSTED!not-for-mail Content-Type: text/plain; charset="UTF-8" Message-ID: <1805136.E3oRWK2ye4@PointedEars.de> From: Thomas 'PointedEars' Lahn Reply-To: Thomas 'PointedEars' Lahn Organization: PointedEars Software (PES) Date: Thu, 09 May 2013 12:26:44 +0200 User-Agent: KNode/4.10.2 Content-Transfer-Encoding: 8Bit X-Face: %i>XG-yXR'\"2P/C_aO%~;2o~?g0pPKmbOw^=NT`tprDEf++D.m7"}HW6.#=U:?2GGctkL,f89@H46O$ASoW&?s}.k+&. <3387373.LFUtorD41v@PointedEars.de> <1emdnRJN--PxdBfMnZ2dnUVZ_sqdnZ2d@westnet.com.au> MIME-Version: 1.0 Lines: 44 NNTP-Posting-Date: 09 May 2013 12:26:44 CEST NNTP-Posting-Host: 63672275.newsspool3.arcor-online.net X-Trace: DXC=XXP[V009:<=^cW`WBF>WQ On 8/05/2013 10:33 PM, Thomas 'PointedEars' Lahn wrote: >> Andrew Poulos wrote: >>> Thanks, though I take JKK and PE's comments on board that the only >>> "real" way to do this is server side. >> >> You have misunderstood me at least. A good solution to your problem is >> to have the client-side script that changes the iframe document in or >> included by the iframe document. For you can only say for sure on the >> *client* side whether there is client-side script support, whether it is >> enabled, and whether the support is sufficient for the task – simply by >> executing the relevant code (which would contain feature tests). >> >> Stefan's suggestion is another good idea, but apparently not applicable >> here. >> >> There is also a third way combining both suggestions, but it might not be >> among the best ones here: You can include the iframe element displaying >> the default document (or put other content) and replace that >> programmatically by client-side (DOM) script with a new iframe element >> that displays another document. This is the same approach you would >> choose if, for example, you wanted to include a static Google Maps map >> (an image) in an HTML document (that would work everywhere), and replace >> it with an interactive Google Maps map if possible (“progressive >> enhancement”). > > Is it "better" to replace one iframe with another instead of just > changing the iframe's src? Depends. > I've tried a way that was previously suggested (dropping the noscript, > and instead dynamically changing the src with a script element > immediately after the iframe element in the HTML) and it seems to do > what I need. It is inherently unreliable, though. -- PointedEars Twitter: @PointedEars2 Please do not Cc: me. / Bitte keine Kopien per E-Mail.