473,811 Members | 3,300 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

SOAP : PHP client /Java server

Hi,
I have a problem with the string array type. I want to send a string
array from the php client to the java server (Webservice with SOAP).

Here is the code :
----- Java server method : -----

public String[] crypte(String[] message, String name) throws
RemoteException {
String[] messageFinal = new String[message.length];

[...]

return messageend;

}catch(Exceptio n e){
throw new RemoteException (e.getMessage() , e);
}
}

----- PHP client : -----
$message= array ("aze","sdsq"," jhgjhgh");
$wsdl = new SOAP_WSDL($url) ;
$client= $wsdl->getProxy();
[...]
$messageCrypte = $client->crypte($messag e, "test");

------------------------
It works very well with a simple String, for example :
$message="jkjhk j"; with
public String[] crypte(String message, String name){...}

but not with a string array. Java doesn't recognise this type.The error
:

"JAXRPCTIE0 1: caught exception while handling request: unexpected
element type:
expected={http://mywebservice/...}StringArray ,actual={http://mywebservice/...}Array"

It works well in the other sens : PHP recognise a string array returned
by the java server : print_r($messag eCrypte).

Thanks for your help.

Jul 17 '05 #1
0 3102

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
1975
by: kj | last post by:
I'm just learning about SOAP, and one of the claims about SOAP that I'm having the hardest time understanding/believing is this business about language independence. Please tell me if I got this right: suppose that I have a SOAP server written Perl that returns Perl objects in response to some method calls. Would a SOAP client written in Python or Java or C++ be able to make any sense out of these Perl objects? Thanks!
4
7851
by: Christian Wilhelm | last post by:
Hi! I have a Problem understanding the deserialisation of SOAP-Responses. The "normal" way, calling a XML WebService is to use WSDL 1) Send Request 2) Get SOAP-Response 3) With Informations out of WSDL transform the SOAP-Response to an Object. Let us call it "Customer".
0
4673
by: Daniel Thune, MCSE | last post by:
I am having a problem with formatting a SOAP Header in a .Net client. The client calls a Java Axis 1.1 based web service. In order to authenticate the caller, the web service call is intercepted by another web service that validates a security token in the header. I have pasted my current SOAP message that my code sends as captured from a trace function that I added. Below that is a sample SOAP message that the developer of the web...
3
10297
by: JRey | last post by:
Does .Net generate the classes for Faults when they are specified in the WSDL. I tried defining them and then generating a proxy, and it did not appear to do it. On the Java side it did generate the class and the ability to serialize that class when putting it on the wire. I was hoping a .Net client would create the appropriate exception class defined in the WSDL and deserialize the message into the appropriate exception class.
5
12528
by: Nate | last post by:
We are attempting to make a request to a web service (we will refer to it as XXXServices) hosted on a Web Logic server from a C# SOAP client. The server responds with a 401 Unauthorized error (that appears in plain text), and causes the client to crash. This C# code has been deployed both as an ASP.NET application and a WinForms app, each of which produced the same result. Further, moving the clients from a Windows XP machine to Windows...
31
2860
by: Bryan Dickerson | last post by:
Ok, simple question: from a VB.Net web service (as I've said before, I'm a newbie to SOAP), how would I get the SOAP body into a string? My boss and I concur that it, at least from our perspective, should be as simple as defining an object and viewing a parameter on that object. My boss has worked with it and I'm still tryin'... TIA! -- TFWBWY...A
7
2359
by: cj | last post by:
Simple Object Access Protocol is new to me. Can anyone point me to a simple soap example? I found something on MS site but they don't tell me what namespace to include for dim SOAPClient = New SOAPClient to work for example.
1
12293
by: Florian Grousset | last post by:
Hi, I'm trying to code a simple C# SOAP client wich query an Axis2 Java SOAP Server. Server side code has been generated from a WSDL file. SOAP requests and responses must both contain a simple String array (not very diffucult I think !). What I've done : 1. WSDL file writing (see at the bottom of this post)
4
3511
by: wbsurfver | last post by:
I have been trying to figure out apache/rampart soap security. We have a soap server in java and the client is PHP. I just read this article which concerns me because it seems to imply rampart/java won't work with PHP. Are there any other good solutions, particularly simple ones ? I have been trying to get rampart/java working for the past 3 days and haven't even gotten to the PHP client part as of yet, then it occured to me to do a google...
1
8289
by: parimalb | last post by:
Hi All, I want to pass an array argument to the java webservice from perl client using SOAP::LITE package. Please let me know if anyone knows about this. The web method declaration in java is like this publishSimpleMetric(Arraylist<String> appinfo,Arraylist<String> metricinfo,String seperator); Now i tried to call the web service from perl client as follows ...
0
10652
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10408
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7673
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6895
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5561
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5700
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4346
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3874
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3026
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.