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
Maluendaster
Forum Contributor
Posts: 124 Joined: Fri Feb 25, 2005 1:14 pm
Post
by Maluendaster » Fri Mar 09, 2007 3:14 pm
I have a site that links to other sites, what i'm trying to do, is when the user clicks the link, it open the other site but with a frame so it doesn't leave my site (kind of like hotmail when you click a link in a mail) .. I have this
index.php
the links are like this :
Code: Select all
link.php?url=http://fmshaon.blogspot.com/2007/01/even-windows-xp-fears-president-bush.html
link.php
Code: Select all
<FRAMESET ROWS="38,*" cols="*">
<FRAME NAME="arriba" SRC="up.php" MARGINWIDTH="10" MARGINHEIGHT="10" SCROLLING="no" FRAMEBORDER="0">
<FRAME NAME="abajo" SRC="<?php echo $url ?>" MARGINWIDTH="10" MARGINHEIGHT="10" SCROLLING="auto" FRAMEBORDER="0">
</FRAMESET>
thank you.
RobertGonzalez
Site Administrator
Posts: 14293 Joined: Tue Sep 09, 2003 6:04 pm
Location: Fremont, CA, USA
Post
by RobertGonzalez » Fri Mar 09, 2007 3:32 pm
Have you tried it? Is register_globals on (which it should not be)?
Maluendaster
Forum Contributor
Posts: 124 Joined: Fri Feb 25, 2005 1:14 pm
Post
by Maluendaster » Fri Mar 09, 2007 5:04 pm
Everah wrote: Have you tried it? Is register_globals on (which it should not be)?
register_globals is off... i tried both ways and it doesnt work...
RobertGonzalez
Site Administrator
Posts: 14293 Joined: Tue Sep 09, 2003 6:04 pm
Location: Fremont, CA, USA
Post
by RobertGonzalez » Fri Mar 09, 2007 5:51 pm
Does the frame layout work without the dynamic addition? I mean, can you do this...
Code: Select all
<FRAMESET ROWS="38,*" cols="*">
<FRAME NAME="arriba" SRC="up.php" MARGINWIDTH="10" MARGINHEIGHT="10" SCROLLING="no" FRAMEBORDER="0">
<FRAME NAME="abajo" SRC="http://fmshaon.blogspot.com/2007/01/even-windows-xp-fears-president-bush.html" MARGINWIDTH="10" MARGINHEIGHT="10" SCROLLING="auto" FRAMEBORDER="0">
</FRAMESET>
Also, have you looked at urlencode() and urldecode()?
Dale
Forum Contributor
Posts: 466 Joined: Fri Jun 21, 2002 5:57 pm
Location: Atherstone, Warks
Post
by Dale » Fri Mar 09, 2007 9:14 pm
So you've tried it using
aswell ??
aaronhall
DevNet Resident
Posts: 1040 Joined: Tue Aug 13, 2002 5:10 pm
Location: Back in Phoenix, missing the microbrews
Contact:
Post
by aaronhall » Fri Mar 09, 2007 9:23 pm
Code: Select all
<a href="link.php?url=http://www.somesite.com" target="abajo">link will open link.php in frame named "abajo", and redirect to somesite.com</a>