interpim Posted July 31, 2008 Share Posted July 31, 2008 So... is there anyway to send Post_vars from one server to a webpage to basically to a remote login to another website? I can't think of how to do it... Link to comment https://forums.phpfreaks.com/topic/117458-post_vars-across-servers/ Share on other sites More sharing options...
DarkWater Posted July 31, 2008 Share Posted July 31, 2008 Use cURL. Link to comment https://forums.phpfreaks.com/topic/117458-post_vars-across-servers/#findComment-604187 Share on other sites More sharing options...
Nhoj Posted July 31, 2008 Share Posted July 31, 2008 As darkwater said, you will need to use cURL. http://us.php.net/manual/en/ref.curl.php Link to comment https://forums.phpfreaks.com/topic/117458-post_vars-across-servers/#findComment-604190 Share on other sites More sharing options...
interpim Posted July 31, 2008 Author Share Posted July 31, 2008 Great Thanks It doesn't seem to be working for me though... anyone see anything wrong with this code? $URL="http://realmwar.warhammeronline.com/realmwar/Index.war"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL,"http://$URL"); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, "war_username=$user_name&war_password=$pword");curl_exec ($ch); curl_close ($ch); Link to comment https://forums.phpfreaks.com/topic/117458-post_vars-across-servers/#findComment-604196 Share on other sites More sharing options...
ronnie88 Posted July 31, 2008 Share Posted July 31, 2008 do you have curl installed on the server? Link to comment https://forums.phpfreaks.com/topic/117458-post_vars-across-servers/#findComment-604203 Share on other sites More sharing options...
DarkWater Posted July 31, 2008 Share Posted July 31, 2008 Remove the http:// from here curl_setopt($ch, CURLOPT_URL,"http://$URL"); Link to comment https://forums.phpfreaks.com/topic/117458-post_vars-across-servers/#findComment-604206 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.