Passing arabic string using cURL
Posted: Wed Oct 28, 2009 12:40 am
Hello,
I am trying to post data using CURL .. but i can't get arabic charaters to pass correctly.
here is my script:
where $msg_body contains arabic characters.
I am trying to post data using CURL .. but i can't get arabic charaters to pass correctly.
here is my script:
Code: Select all
// Create a curl handle
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,"$address");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, "MessageBody=$msg_body");
// Execute
curl_exec($ch);
// Close handle
curl_close($ch);where $msg_body contains arabic characters.