#33659 [Opn->Bgs]: php_soap.dll problem with arrays

From: Date: Tue, 12 Jul 2005 13:21:44 +0000
Subject: #33659 [Opn->Bgs]: php_soap.dll problem with arrays
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-81734@lists.php.net to get a copy of this message
ID: 33659 Updated by: tony2001@php.net Reported By: wase1 at gmx dot net -Status: Open +Status: Bogus Bug Type: SOAP related Operating System: Win 2K SP 4 + IIS 5.0 PHP Version: 5.0.4 New Comment: Set $e to "blah" and you'll get the same error. Not PHP bug -> bogus. Previous Comments: ------------------------------------------------------------------------ [2005-07-12 14:42:15] wase1 at gmx dot net Description: ------------ Sorry, my englisch is bad. Problem: I try tu use extension php_soap.dll with IIS 5.0 to build a webservice client. If my eMail ist static $param->EmailAddress = "wase1@gtmx.net"; no problem. If it is dynamic $param->EmailAddress = "$e"; Problem: Fatal error: Uncaught SoapFault exception: [soap:Server] Server was unable to process request. --> Index was outside the bounds of the array. in c:\Inetpub\wwwroot\walter\index.php:52 Stack trace: #0 c:\Inetpub\wwwroot\walter\index.php(52): SoapClient->__call('IsValidEMail', Array) #1 c:\Inetpub\wwwroot\walter\index.php(52): SoapClient->IsValidEMail(Object(stdClass)) #2 {main} thrown in c:\Inetpub\wwwroot\walter\index.php on line 52 Reproduce code: --------------- <? if(!empty($_REQUEST['email'])){ $WSDL='http://www.webservicex.net/ValidateEmail.asmx?WSDL'; $soapclient = new SoapClient($WSDL); echo "<br><pre>"; $e = trim($_REQUEST['email']); $arr = array(); $arr['EmailAddress'] = "$e"; $res = $soapclient->IsValidEMail($arr); print_r($res); echo "<hr>"; if(!empty($res->IsValidEMailResult)) echo "$e Is eMail"; else echo "$e Is No eMail"; echo "</pre><br>"; } ?> Expected result: ---------------- I wrote everything in the Description. Actual result: -------------- I wrote everything in the Description. Fatal error: Uncaught SoapFault exception: [soap:Server] Server was unable to process request. --> Index was outside the bounds of the array. in c:\Inetpub\wwwroot\walter\index.php:52 Stack trace: #0 c:\Inetpub\wwwroot\walter\index.php(52): SoapClient->__call('IsValidEMail', Array) #1 c:\Inetpub\wwwroot\walter\index.php(52): SoapClient->IsValidEMail(Object(stdClass)) #2 {main} thrown in c:\Inetpub\wwwroot\walter\index.php on line 52 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=33659&edit=1

« previous php.bugs (#81734) next »