Re: Re: Can it be Done?

From: Date: Sun, 06 Oct 2002 20:10:59 +0000
Subject: Re: Re: Can it be Done?
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-119013@lists.php.net to get a copy of this message
To produce such a JavaScript: define('_DOMBASE', 'http://yourdomain.com'); echo '<SCRIPT language="JavaScript" type="text/javascript">'."\n" .'if (document.location == top.location)'."\n" .' top.location="'._DOMBASE.'/index.php?goto=' .base64_encode($_SERVER["REQUEST_URI"]).'";'."\n" .'</SCRIPT>'; where the index.php works like: <? if (!isset($_GET['goto'])) $goto = "home.php"; else $goto = base64_decode($_GET['goto']); ?> <FRAMESET> <someframes> <FRAME src="http://yourdomain.com/<? echo $goto; ?>"> </FRAMESET> As Stephen reported me recently, this also works with iframes. Sascha Am Sonntag, 6. Oktober 2002 21:37 schrieb Adriano: > Hi people, > > @ Edwin wrore: > > 'Not really sure, but perhaps, with Javascript. > > > > But I'd rather recommend you to give up iframes... ;) > > Can you post an example of Javascript code checking for _parent frame? > By the way, what's wrong with iframes? > bye, > Adr

« previous php.general (#119013) next »