Dear Sirs,
I try to post xml file with following script;
Until today I was using following script for http post. But now I shoul post
https. When I changing HTTP to HTTPS, I am getting this error
Bad Request
HTTP/1.1 400 Bad Request Date: Mon, 03 Mar 2003 21:07:18 GMT Server:
Apache/1.3.27 (Unix) Connection: close Content-Type: text/html;
charset=iso-8859-1
Any idea, am I doing right to use following method to post xml file. And why
I can not post https?
-----------------------------------------------
$str = "xml markuped text.........";
$len = strlen($str);
$p = "POST /servlet/com.oksijen.bulkmessaging.xml.SmsToMany
HTTP/1.1\r\n";
$p.= "Host: 212.65.135.163 \r\n";
$p.= "Content-type: application/x-www-form-urlencoded\r\n";
$p.= "Content-length: $len\n\n";
$p.= "$str\n";
$p.= "\r\n";
$server = "212.65.135.163";
$connection_timeout = 10;
$fp = fsockopen ($server, 80, &$errno, &$errstr, $connection_timeout);
fputs ($fp,$p);
$recdata = "";
while (!feof($fp))
{
$recdata .= fgets ($fp,128);
print "$recdata";
}
fclose ($fp);
$sonuc = trim(substr($recdata,-19));
$pos = 0;
$pos = strpos($recdata, "Message Failed");
"Qt" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Dear Sirs,
>
> I am trying to post a xml file to following http. But I can not. where can
I
> find some source to read.
>
> https://xxx.xxx.xxx.xx/servlet/com.oks.buing.xml.detdrd
>
> Any help welcome
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php