holyearth Posted December 19, 2006 Share Posted December 19, 2006 Hello,I'm trying to pass a url thru for redirection....example....http://www.example.com/index.php?r=http://www.google.comI must pass it thru that way...Here's my code but it's not working....[code]<?php$data = urlencode($HTTP_GET_VARS['r']);?><HTML><HEAD><META HTTP-EQUIV=Refresh CONTENT="0; URL=<? echo("$data"); ?>"></HEAD></HTML>[/code]I think the urlencode is wrong??Please help. Thanks in advance! Quote Link to comment Share on other sites More sharing options...
alpine Posted December 19, 2006 Share Posted December 19, 2006 if you echo it you will se that it's transformed to [color=red]http%3A%2F%2Fwww.google.com[/color]try [color=blue]$data = htmlspecialchars($_GET['r']);[/color] instead, and if there is no particular reason, quit the habit of using older predefined variables ($HTTP_*_VARS) and start using $_GET, $_POST etc. instead. Quote Link to comment Share on other sites More sharing options...
m1rkd1rk Posted December 19, 2006 Share Posted December 19, 2006 I recommend using PHPMyAdmin to delete records in a table. If you are on a webhost, ask about it, if not download it and install it. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.