Re: Simple Example - Google Spell check - no worky

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Christian -- still hanging in there with me. Thanks :)

For some reason, I was missing some files in my SOAP libraries.
So I downloaded a new archive from pear.php.net. I've installed the latest
SOAP, HTTP and NET libraries. All are directories where this example is
running from - so all are relative paths.

I get further - no errors but no results and it appears to hang at the
soapclient call to doSpellingSuggestion().

I tried this both with the proxy method and non-proxy method -- same no
results or apparent return after the call above.
I add a echo stmt after that call and never see it.

Commenting out the $devkey define - and I will get the same error that you
noted.

Can you get a dev key and give it a try?
Works just fine with nusoap.

Regards,
Blaine

"Christian Wenz" <chw@hauser-wenz.de> wrote in message
3FD4AF3A.9024D41D@hauser-wenz.de">news:3FD4AF3A.9024D41D@hauser-wenz.de...
> seems to work for me (PHP 4.3.4, PEAR::SOAP 0.8.RC1), I get the following
> output:
>
> Notice: Undefined variable: devKey in /path/to/soaptest.php on line 11
>
> Notice: Undefined index: p in /path/to/soaptest.php on line 12
> No result or NULL returned
>
> (which is OK since I have no variable devKey and no POST variable p).
>
> Regards
> Christian
>
>
> Blaine Lang wrote:
>
> > Hum,
> >
> > Now I get the following error:
> >
> > Call to undefined function: getproxy()
> >
> > Complete code is now:
> >
> >     // include the class
> >     require_once 'SOAP/Client.php';
> >     // create a instance of the SOAP client object
> >     $wsdl = new SOAP_WSDL('http://api.google.com/GoogleSearch.wsdl');
> >     $soapclient = $wsdl->getProxy();
> >
> >    // set up an array containing input parameters to be
> >     // passed to the remote procedure
> >     $parms = array(
> >         'key'       => $devKey,         // Googlelicense key
> >         'phrase'    => $_POST['p']      // term to check
> >     );
> >
> >     // invoke the method on the server
> >     $result =
$soapclient->doSpellingSuggestion($parms,'urn:GoogleSearch');
> >     if (!PEAR::isError($result)) {
> >          echo "Google suggests <b>" . $result . "</b> for the term <b>"
.
> > $_POST['p'] . "</b><br>";
> >      } else {
> >         echo "No result or NULL returned<br>";
> >     }

-- 
PHP Soap Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Kernel Newbies]     [PHP Database]     [Yosemite]

  Powered by Linux