Bonjour,
J'ai un problème avec le retour XML en SOAP.
J'utilise la technologie PHP.
En fait mon webservice fonctionne correctement lorsque je retourne un tableau de moins de 12 entrées sinon il me retourne une erreur '["faultstring"]=>
string(33) "looks like we got no XML document"' .
Comment faire pour remédier à ce problème ?
Faut-il augmenter la mémoire?
Voici un exemple d'un retour de la fonction lorsque ca fonctionne :
Sinon l'erreur :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2 <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope" xmlns:ns1="urn:NavisionWs" xmlns:enc="http://www.w3.org/2003/05/soap-encoding" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><env:Body xmlns:rpc="http://www.w3.org/2003/05/soap-rpc"><ns1:recupererPrixStockResponse env:encodingStyle="http://www.w3.org/2003/05/soap-encoding"><rpc:result>tabProduit</rpc:result><tabProduit enc:itemType="enc:Struct" enc:arraySize="12" xsi:type="enc:Array"><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMVHS1</id><tarif1 xsi:type="xsd:string">.99000000000000000000</tarif1><tarif2 xsi:type="xsd:string">.99000000000000000000</tarif2><tarif3 xsi:type="xsd:string">.99000000000000000000</tarif3><tarif4 xsi:type="xsd:string">.99000000000000000000</tarif4><tarif5 xsi:type="xsd:string">.99000000000000000000</tarif5><tarif6 xsi:type="xsd:string">.95000000000000000000</tarif6><tarif7 xsi:type="xsd:string">.99000000000000000000</tarif7><stock xsi:type="xsd:int">6</stock><stockReel xsi:type="xsd:int">6</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMSG100G</id><tarif1 xsi:type="xsd:string">6.55000000000000000000</tarif1><tarif2 xsi:type="xsd:string">6.55000000000000000000</tarif2><tarif3 xsi:type="xsd:string">6.55000000000000000000</tarif3><tarif4 xsi:type="xsd:string">6.55000000000000000000</tarif4><tarif5 xsi:type="xsd:string">6.55000000000000000000</tarif5><tarif6 xsi:type="xsd:string">5.50000000000000000000</tarif6><tarif7 xsi:type="xsd:string">6.55000000000000000000</tarif7><stock xsi:type="xsd:int">4</stock><stockReel xsi:type="xsd:int">4</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMSG100C</id><tarif1 xsi:type="xsd:string">6.55000000000000000000</tarif1><tarif2 xsi:type="xsd:string">6.55000000000000000000</tarif2><tarif3 xsi:type="xsd:string">6.55000000000000000000</tarif3><tarif4 xsi:type="xsd:string">6.55000000000000000000</tarif4><tarif5 xsi:type="xsd:string">6.55000000000000000000</tarif5><tarif6 xsi:type="xsd:string">5.50000000000000000000</tarif6><tarif7 xsi:type="xsd:string">6.55000000000000000000</tarif7><stock xsi:type="xsd:int">28</stock><stockReel xsi:type="xsd:int">28</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMS600B</id><tarif1 xsi:type="xsd:string">26.59000000000000000000</tarif1><tarif2 xsi:type="xsd:string">26.45000000000000000000</tarif2><tarif3 xsi:type="xsd:string">26.30000000000000000000</tarif3><tarif4 xsi:type="xsd:string">26.25000000000000000000</tarif4><tarif5 xsi:type="xsd:string">25.97000000000000000000</tarif5><tarif6 xsi:type="xsd:string">26.83000000000000000000</tarif6><tarif7 xsi:type="xsd:string">25.30000000000000000000</tarif7><stock xsi:type="xsd:int">14</stock><stockReel xsi:type="xsd:int">14</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMRHS1</id><tarif1 xsi:type="xsd:string">5.53000000000000000000</tarif1><tarif2 xsi:type="xsd:string">5.50000000000000000000</tarif2><tarif3 xsi:type="xsd:string">5.47000000000000000000</tarif3><tarif4 xsi:type="xsd:string">5.40000000000000000000</tarif4><tarif5 xsi:type="xsd:string">5.35000000000000000000</tarif5><tarif6 xsi:type="xsd:string">5.41000000000000000000</tarif6><tarif7 xsi:type="xsd:string">5.00000000000000000000</tarif7><stock xsi:type="xsd:int">0</stock><stockReel xsi:type="xsd:int">1</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMPC302U3</id><tarif1 xsi:type="xsd:string">14.50000000000000000000</tarif1><tarif2 xsi:type="xsd:string">14.50000000000000000000</tarif2><tarif3 xsi:type="xsd:string">14.50000000000000000000</tarif3><tarif4 xsi:type="xsd:string">14.50000000000000000000</tarif4><tarif5 xsi:type="xsd:string">14.50000000000000000000</tarif5><tarif6 xsi:type="xsd:string">10.00000000000000000000</tarif6><tarif7 xsi:type="xsd:string">14.50000000000000000000</tarif7><stock xsi:type="xsd:int">40</stock><stockReel xsi:type="xsd:int">40</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMPB84IW</id><tarif1 xsi:type="xsd:string">30.10000000000000000000</tarif1><tarif2 xsi:type="xsd:string">29.59000000000000000000</tarif2><tarif3 xsi:type="xsd:string">29.10000000000000000000</tarif3><tarif4 xsi:type="xsd:string">28.48000000000000000000</tarif4><tarif5 xsi:type="xsd:string">28.18000000000000000000</tarif5><tarif6 xsi:type="xsd:string">28.95000000000000000000</tarif6><tarif7 xsi:type="xsd:string">27.45000000000000000000</tarif7><stock xsi:type="xsd:int">15</stock><stockReel xsi:type="xsd:int">16</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMPB112IW</id><tarif1 xsi:type="xsd:string">36.50000000000000000000</tarif1><tarif2 xsi:type="xsd:string">35.89000000000000000000</tarif2><tarif3 xsi:type="xsd:string">35.30000000000000000000</tarif3><tarif4 xsi:type="xsd:string">34.54000000000000000000</tarif4><tarif5 xsi:type="xsd:string">34.17000000000000000000</tarif5><tarif6 xsi:type="xsd:string">35.10000000000000000000</tarif6><tarif7 xsi:type="xsd:string">33.28000000000000000000</tarif7><stock xsi:type="xsd:int">13</stock><stockReel xsi:type="xsd:int">14</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMMH200U3</id><tarif1 xsi:type="xsd:string">44.77000000000000000000</tarif1><tarif2 xsi:type="xsd:string">44.27000000000000000000</tarif2><tarif3 xsi:type="xsd:string">43.78000000000000000000</tarif3><tarif4 xsi:type="xsd:string">42.37000000000000000000</tarif4><tarif5 xsi:type="xsd:string">41.91000000000000000000</tarif5><tarif6 xsi:type="xsd:string">41.00000000000000000000</tarif6><tarif7 xsi:type="xsd:string">40.83000000000000000000</tarif7><stock xsi:type="xsd:int">0</stock><stockReel xsi:type="xsd:int">0</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMK200M</id><tarif1 xsi:type="xsd:string">2.99000000000000000000</tarif1><tarif2 xsi:type="xsd:string">2.99000000000000000000</tarif2><tarif3 xsi:type="xsd:string">2.99000000000000000000</tarif3><tarif4 xsi:type="xsd:string">3.85000000000000000000</tarif4><tarif5 xsi:type="xsd:string">3.80000000000000000000</tarif5><tarif6 xsi:type="xsd:string">3.95000000000000000000</tarif6><tarif7 xsi:type="xsd:string">3.80000000000000000000</tarif7><stock xsi:type="xsd:int">118</stock><stockReel xsi:type="xsd:int">119</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMHE135</id><tarif1 xsi:type="xsd:string">19.50000000000000000000</tarif1><tarif2 xsi:type="xsd:string">19.50000000000000000000</tarif2><tarif3 xsi:type="xsd:string">19.50000000000000000000</tarif3><tarif4 xsi:type="xsd:string">19.75000000000000000000</tarif4><tarif5 xsi:type="xsd:string">19.70000000000000000000</tarif5><tarif6 xsi:type="xsd:string">21.51000000000000000000</tarif6><tarif7 xsi:type="xsd:string">19.70000000000000000000</tarif7><stock xsi:type="xsd:int">8</stock><stockReel xsi:type="xsd:int">8</stockReel></item><item xsi:type="enc:Struct"><id xsi:type="xsd:string">ZMGWB8800GTS</id><tarif1 xsi:type="xsd:string">15.00000000000000000000</tarif1><tarif2 xsi:type="xsd:string">15.00000000000000000000</tarif2><tarif3 xsi:type="xsd:string">15.00000000000000000000</tarif3><tarif4 xsi:type="xsd:string">15.00000000000000000000</tarif4><tarif5 xsi:type="xsd:string">15.00000000000000000000</tarif5><tarif6 xsi:type="xsd:string">12.00000000000000000000</tarif6><tarif7 xsi:type="xsd:string">15.00000000000000000000</tarif7><stock xsi:type="xsd:int">17</stock><stockReel xsi:type="xsd:int">17</stockReel></item></tabProduit></ns1:recupererPrixStockResponse></env:Body></env:Envelope>
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74 object(SoapFault)#3 (10) { ["message":protected]=> string(33) "looks like we got no XML document" ["string":"Exception":private]=> string(0) "" ["code":protected]=> int(0) ["file":protected]=> string(32) "xxxx.php" ["line":protected]=> int(22) ["trace":"Exception":private]=> array(2) { [0]=> array(6) { ["file"]=> string(32) "/xxxx.php" ["line"]=> int(22) ["function"]=> string(6) "__call" ["class"]=> string(10) "SoapClient" ["type"]=> string(2) "->" ["args"]=> array(2) { [0]=> string(18) "recupererPrixStock" [1]=> array(1) { [0]=> object(stdClass)#1 (2) { ["login"]=> string(4) "xxxx" ["password"]=> string(4) "xxxx" } } } } [1]=> array(6) { ["file"]=> string(32) "/xxx.php" ["line"]=> int(22) ["function"]=> string(18) "recupererPrixStock" ["class"]=> string(10) "SoapClient" ["type"]=> string(2) "->" ["args"]=> array(1) { [0]=> object(stdClass)#1 (2) { ["login"]=> string(4) "XXXX" ["password"]=> string(4) "XXXX" } } } } ["previous":"Exception":private]=> NULL ["faultstring"]=> string(33) "looks like we got no XML document" ["faultcode"]=> string(6) "Sender" ["faultcodens"]=> string(39) "http://www.w3.org/2003/05/soap-envelope" }
Partager