vendredi 22 mai 2015

array to string error php [duplicate]

This question already has an answer here:

please help sort this out. Here is my code

$message = $_REQUEST['message'];
    $recipient ="+250788353869";//$_REQUEST['recipient'];       
    $account="";
    $pin="";        
    ini_set("soap.wsdl_cache_enabled", "0"); // Set to zero to avoid caching WSDL
    $soapClient = new SoapClient('http://ift.tt/1FCqAVB');     
    $result = $soapClient->ksend(array('account'=>$account,'pin'=>$pin,'sender'=>$sender_phone,'message'=>$message,'phone'=>$recipient));    
    //reply,balance,status 
    echo $result['balance'];

and here is the error on the screen

Notice: Array to string conversion in /opt/lampp/htdocs/unifiedschoolsystem/Admin/sms/smspost.php on line 23

the line 23 is:

$result = $soapClient->ksend(array('account'=>$account,'pin'=>$pin,'sender'=>$sender_phone,'message'=>$message,'phone'=>$recipient));




Aucun commentaire:

Enregistrer un commentaire