SSL: fatal protocol error
Posted: Thu Nov 10, 2005 7:08 pm
I am trying to execute this code which will send some info on over a secure connection. However when executing it I get the following warning message:
https://xx.xxx.xxx.xx:41xxx/cgi-bin/migration-bmn.cgi?cmd=registerplayer&name=plok&cageId=5000002&passwd=22132453&skinId=55000&location=USA&affiliateId=100&email=test%40test.com
Warning: file_get_contents() [function.file-get-contents]: SSL: fatal protocol error in c:\program files\apache....
Hence I dnt get any response from the server.
Anyone with an idea how this could be solved?
Thanks a lot..
https://xx.xxx.xxx.xx:41xxx/cgi-bin/migration-bmn.cgi?cmd=registerplayer&name=plok&cageId=5000002&passwd=22132453&skinId=55000&location=USA&affiliateId=100&email=test%40test.com
Warning: file_get_contents() [function.file-get-contents]: SSL: fatal protocol error in c:\program files\apache....
Hence I dnt get any response from the server.
Anyone with an idea how this could be solved?
Thanks a lot..
Code: Select all
<?
ignore_user_abort ( 'true' );
set_time_limit ( 0 );
$connection = pg_connect("dbname=BIMS_DEV user=postgres host=10.1.1.46");
if (!$connection) {
print("Connection Failed.");
exit;
}
$myresult = pg_exec($connection, "Select cageid,screename,affliateid,password,skinid,location from tribeca.dummy");
for ($lt = 0; $lt < pg_numrows($myresult); $lt++) {
$name = pg_result($myresult, $lt, 1);
$cageid = pg_result($myresult, $lt, 0);
$password = pg_result($myresult, $lt, 3);
$skinid = pg_result($myresult, $lt, 4);
$location = pg_result($myresult, $lt, 5);
//$affid = pg_result($myresult, $lt, 2);
$affid=100;
$url= "https://xx.xxx.xxx.xx:41xxx/cgi-bin/migration-bmn.cgi?cmd=registerplayer&name=$name&cageId=$cageid&passwd=$password&skinId=$skinid&location=$location&affiliateId=$affid&email=test%40test.com";
$html = file_get_contents($url);
$tok=strtok($html, "\n");
while($tok){
$toks[] = $tok;
$tok=strtok("\n"); //get next string
}
$errorCode = $toks[0];
$pieces=explode("=",$errorCode);
$req_errCode= $pieces[1];
if ($req_errCode == "0")
{
$myresult2 = pg_exec($connection, "Update tribeca.dummy set migrated = true where cageid=$cageid");
}
$myresult3 = pg_exec($connection, "Update tribeca.dummy set errorcode=$req_errCode where cageid=$cageid");
}