Hi,

I am new to SOAP so maybe my question is stupid, but:

I want to read the Adress Books (Contacts) of an
users Addressbook and bring them to a LDAP Server
(to have the numbers available in our IP Phones).

Groupwise (POA) is Version 8.0.2HP1 running on Netware.

I started with this example:
ftp://sdk.provo.novell.com/ndk/gwsoa.../phpClient.ZIP

and modified the Code like:

PHP Code:
<?php
require_once('./GWService/GroupwiseService.php');

$classmap = array(
        
'Authenication' => 'Authenication',
        
'PlainText' => 'PlainText',
        
'loginRequest' => 'loginRequest',
        
'loginResponse' => 'loginResponse',
        
'logoutRequest' => 'logoutRequest',
        
'logoutResponse' => 'logoutResponse',
        
'UserInfo' => 'UserInfo',
        );

$gwservice = new GroupwiseService(
        
"./WSDL/groupwise.wsdl",
        array(
            
"location" => "http://server:7191/soap",
            
"classmap" => $classmap,
            
"trace" => true)
        );

// do login
$pt = new PlainText();
$pt->username "user";
$pt->password "XXX";

$lr = new loginRequest();
$lr->auth $pt;
$lr->language "en";
$lr->version "1.2";
$lr->application "phpClient";

$lres $gwservice->loginRequest($lr);

// check for errors
if ( $lres->code != )
{
    print 
"code: " $lres->code " - " $lres->description "\n";
}
else if ( 
$lres['status']->code == )
{
    
// save off the session string
    
$gwservice->session $lres['session'];
    print 
"Name: " $lres['userinfo']->name "\n";
}

if ( 
$gwservice->session != "" )
{
    
      print 
"getting Addressbooks...\n";
     
      
$abreq = new getAddressBookListRequest();
     
      
$abres $gwservice->getAddressBookListRequest($abreq);
      
      
print_r($abres);
    print 
"Finished\n";
    
}    


// logout
if ( $gwservice->session != "" )
{
    print( 
"logout\n" );
    
$logout = new logoutRequest();
    
$gwservice->logoutRequest($logout);
    
$gwservice->session "";
}

?>
But all I get is
Code:
Notice: Trying to get property of non-object in Addressbook.php on line 36
Name: User
getting Addressbooks...
stdClass Object
(
    [status] => stdClass Object
        (
            code => 59920
            [description] => Missing session string
        )

)
Finished
logout
Can anyone help me with that?

cu SveN