PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Moderator: General Moderators
suthie
Forum Commoner
Posts: 68 Joined: Sat Jun 09, 2007 10:46 am
Post
by suthie » Tue Jul 17, 2007 7:04 pm
How can i use the header() function to target a different window?
What I want to do is target the whole window from within an iframe... can i do this with header() ?
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Tue Jul 17, 2007 7:48 pm
header() cannot target any window.
suthie
Forum Commoner
Posts: 68 Joined: Sat Jun 09, 2007 10:46 am
Post
by suthie » Tue Jul 17, 2007 8:55 pm
is there a function that can target a window?
and btw i mean the current window, not a totally different window. i just want to access the window from within an iframe
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Tue Jul 17, 2007 9:13 pm
Nothing in PHP can target a window. That's entirely client-side functionality.
suthie
Forum Commoner
Posts: 68 Joined: Sat Jun 09, 2007 10:46 am
Post
by suthie » Thu Jul 19, 2007 4:20 pm
could i use javascript within php like this:
Code: Select all
<?php
...php code...
if(condition){
?>
...javascript redirect code here...
<?php
}
?>
?
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Thu Jul 19, 2007 11:49 pm
Potentially.