Bug #48717 [Com]: Cannot pass datatype long (> 2147483647) in SOAP requests
| From: | dev dot rindeal+bugs dot php dot net at outlook dot com | Date: | Fri, 30 May 2014 11:17:05 +0000 |
| Subject: | Bug #48717 [Com]: Cannot pass datatype long (> 2147483647) in SOAP requests | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-185986@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=48717&edit=1
ID: 48717
Comment by: dev dot rindeal+bugs dot php dot net at outlook dot
com
Reported by: rob at zcore dot org
Summary: Cannot pass datatype long (> 2147483647) in SOAP
requests
Status: Open
Type: Bug
Package: SOAP related
Operating System: Debian GNU/Linux
PHP Version: 5.2.11
Block user comment: N
Private report: N
New Comment:
PHP 5.5.12 x86 on Windows 8 and it's still there. Thankfully the workaround in the comment #1
works for me. Thank you "ghostbaer at gmx dot de", you saved my work.
Previous Comments:
------------------------------------------------------------------------
[2010-10-27 20:46:44] pajoye@php.net
try:
$a = "1234";
$b = 1234;
if ($a == $b) echo "hopla";
well known problem related to php auto casting, or better said, typeless.
------------------------------------------------------------------------
[2010-10-27 20:20:24] periklis dot tsirakidis at mayflower dot de
Ouch... Pierre,
one serious notice is, that we changed the wsdl for <options> from xsd:long to xsd:string and
the problem is still there. Do we have here an auto-casting from string to long?
Any ideas?
------------------------------------------------------------------------
[2010-10-27 20:15:57] pajoye@php.net
PHP on windows uses 32bit integer for long, always. That's not possible to fix easily either.
Two choices, either convert to double when an integer overflow happens, or wait until we have big
integer support.
------------------------------------------------------------------------
[2010-10-27 20:05:05] periklis dot tsirakidis at mayflower dot de
Hey guys,
this serious bug is still damaging SOAP envelopes with long in there. We have the same problem on
PHP 5.3.2 and 5.3.3 (32Bit) under Windows 2008R2 (64Bit) with IIS7. I think the bug reporter posted
exactly the last request in order to fix this issue. Here is ours:
<SOAP-ENV:Envelope xmlns:SOAP-ENV=\"http://schemas.xmlsoap.org/soap/envelope/\"
xmlns:ns1=\"http://rsp.soap.atlas.jungheinrich.de/\">
<SOAP-ENV:Body>
<ns1:sendConfigurationData>
<arg0>
<ffzId>96D</ffzId>
<gatewayIds>3B27DE81</gatewayIds>
</arg0>
<arg1>
<header>
<options>2147483647</options>
<messageId>36</messageId>
<created>2010-10-27T16:54:19</created>
<expires>1970-01-01T01:00:00</expires>
<deviceId>96D</deviceId>
<formatRevision>0</formatRevision>
</header>
</arg1>
</ns1:sendConfigurationData>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
I believe that it is time to fix this loooong problem with long datatypes.
My 2 cents
Periklis
------------------------------------------------------------------------
[2009-09-28 19:12:35] sjoerd@php.net
To properly diagnose this bug, we need the SOAP request and response. You can get that using a
sniffer (Wireshark) or using __getLastRequest and __getLastResponse. See the PHP manual for
information on these methods.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=48717
--
Edit this bug report at https://bugs.php.net/bug.php?id=48717&edit=1