luissimoes Posted November 4, 2006 Share Posted November 4, 2006 Hi how can i pass a value within a url that contains characters like ? and & and so on?Imagina this: http://***.blablabla.com?link=http://***.blaone.com?test=true&return=falseSee?What i wanted was that the target picked up the value http://***.blaone.com?test=true&return=fals in $_GET['link']...Best Regards Link to comment https://forums.phpfreaks.com/topic/26121-pass-variables-from-url-solved/ Share on other sites More sharing options...
jwk811 Posted November 4, 2006 Share Posted November 4, 2006 you can use a form with GET method or you can put the variable inside the url like on the script like this:http://www.website.com/index?v=$variable&b=$variablesomething like that.. if im leaving something out someone else please correct me Link to comment https://forums.phpfreaks.com/topic/26121-pass-variables-from-url-solved/#findComment-119452 Share on other sites More sharing options...
luissimoes Posted November 4, 2006 Author Share Posted November 4, 2006 I think you didnt get it...imagine $variable1 = '***.blabla.com?test=true&return=false'can't you see? there will be several & and several ? but i think the ? are ok... the problem lies in the & symbols.Regards Link to comment https://forums.phpfreaks.com/topic/26121-pass-variables-from-url-solved/#findComment-119453 Share on other sites More sharing options...
joshi_v Posted November 4, 2006 Share Posted November 4, 2006 Try to pass u r variable values in single quotes. hope it will solve your problem.Regards,Joshi. Link to comment https://forums.phpfreaks.com/topic/26121-pass-variables-from-url-solved/#findComment-119510 Share on other sites More sharing options...
luissimoes Posted November 4, 2006 Author Share Posted November 4, 2006 This was the final statement and it didn't worked:http://***.blabla.com?clickTag='http://blabla.com/index.php?option=test&task=icansee&id=12'&url_redirect='http://***.blabla.com/index.php?option=redirectme&task=icansee&id=12'Damn this is a pretty new situation ehehe Link to comment https://forums.phpfreaks.com/topic/26121-pass-variables-from-url-solved/#findComment-119589 Share on other sites More sharing options...
AbydosGater Posted November 4, 2006 Share Posted November 4, 2006 you cant get rid of the & in the URL, it signifies a new variable thats being passed, if you take out the & you would be left with 1 big long messy variable in the URL Link to comment https://forums.phpfreaks.com/topic/26121-pass-variables-from-url-solved/#findComment-119595 Share on other sites More sharing options...
kenrbnsn Posted November 4, 2006 Share Posted November 4, 2006 Can you post the portion of your script where you are sending this string?Ken Link to comment https://forums.phpfreaks.com/topic/26121-pass-variables-from-url-solved/#findComment-119602 Share on other sites More sharing options...
luissimoes Posted November 4, 2006 Author Share Posted November 4, 2006 I have solved the problem by using URLENCODE().Thank you very much for the help and time spent in this thread.Best Regards,Luis Simoes Link to comment https://forums.phpfreaks.com/topic/26121-pass-variables-from-url-solved/#findComment-119682 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.