php - Uncaught SoapFault exception: Call to undefined method -


I am trying to work on a very small SOAP system, but I am struggling with a small problem for a few days And Google can not help me ...

What do I have to do: I want to do some things in some variables, which I am passing in a class. Problem: I want to use my server.php file as an object in the incoming class. But this is not possible.

My server PHP file:

  class lid {public $ number good year; // This example is for personal purposes only private $ TU; Private $ school; Private $ value; Public function __ conversion ($ dump) {$ this- & gt; Tew = "dump:". $ Dump; } Public function getPrice () {Return $ this- & gt; value; }} Class functions {public function __ composition (lid $ lid) {$ lid- & gt; Milpris (); // what to do to get me the new lid ($ lid-> number of year); }} $ Classmap = array ('lid' = & gt; 'lid'); $ Server = new SOAP server (zero, array ('classmaps' = & gt; $ clamsap, 'uri' = 'gt;' http://127.0.0.1/ns/soap/ ")); $ Server & gt; SetClass ("Functies"); $ Server & gt; take care ();   

In class "functions" I want to export by SOAP in all the ways. I am using Transport Class lid as an argument. What I really want to do is call the $ lid methods of the coming class. When I try to run the client script, it is returning the following error: Unquoted soapfile exception: [SOAP-ENV: server] Call the undefined method stdClass :: getPrice ()

I understand. PHP thinks that the logic $ lid is a square, and not an object.

So, my question: 1) How can I make the $ lid an object? 2) How can I access my personal / public variable? I tried to do this through the $ lid-> numbers over the years but this is just returning an empty string.

Thank you in advance

About two years ago, I have tried that you Actually what are you trying to do here.

From those days, I use less SOAP as possible. In reality, SOAP works very well (I understand that "due to ambiguous, unnecessary and verbose definition of the WSDL," and "quite" for the horrible, unclear error messages of the PHP SOAP library) Very simple data structures (If I remember well then I can be helpful without using any problem) "<"

As soon as I have a full class " Shared "between client and server It was impossible for me to reach the goal (for example, unable to execute a method on transferring objects).

So I left this idea before taking too much time and that To get rid of headache, and data h, all possible was getting only simple structures via SOAP ...

H.H

Comments

Popular posts from this blog

qt - switch/case statement in C++ with a QString type -

python - sqlite3.OperationalError: near "REFERENCES": syntax error - foreign key creating -

Python's equivalent for Ruby's define_method? -