Forum Moderators: coopster

Message Too Old, No Replies

PHP redirect with a target

         

stillsix

9:10 pm on Dec 16, 2004 (gmt 0)

10+ Year Member



I have a page with an IFRAME nested inside it and I've named the IFRAME name="interface". Is there a way to do a header REDIRECT and specify this target IFRAME within a page or maybe have PHP print the javascript window.location page and target the IFRAME?

If not any suggestions on how to handle something similar or a work around.

Thanks in advance.

Andrew83

9:58 pm on Dec 16, 2004 (gmt 0)

10+ Year Member



You got it write, use PHP to output a JavaScript that will load whatever you want in the IFRAME. Something like this would work OK:

<?php
echo '<script language="javascript">'."\n";
echo ' window.opne("'.$page.'", "iframe");'."\n";
echo '</script>'."\n";
?>