hi,

I try to add a user using a small php-scipt (just for understanding how it 
works).

I can login as admin (and get returncode "1" for login). If I put a wrong 
passwors I get an 
errorcode... So I think I am logged in.

Call of addNewUser does not get an error but gets no result at all. If I put a 
wrong SID I get 
an error "you must login as admin..." - that seems to work. But I don_t get any 
error message 
e.g. when I misspell a paramater like "lastname". The user is not added at 
alll...

I am using openmeetings 2.1.1 running on ubuntu lucid using php-soap library 
from repository.

Here my snipplet:


<?php

# get the session-id
$userService = new SoapClient 
("http://localhost:5080/openmeetings/services/UserService?wsdl";);
$sess = $userService->getSession();
$sid = $sess->return->session_id;


# login as administrator
$result = $userService-
>loginUser(array("SID"=>$sid,"username"=>'my_admin_name',"userpass"=>'my_admin_pass'));

# add a new user
$result = $userService-
>addNewUser(array("SID"=>$sid,"username"=>'paul',"userpass"=>'abcDEF5ft',"lastname"=>'',"firstname"=>'',"email"=>'test@a.b',"additionalname"=>'',"street"=>'',"zip"=>'',"fax"=>'',"states_id"=>'',"town"=>'',"language_id"=>'2',"baseURL"=>'http://url_here.com'));

?>


I don't understand what is missing or going wrong... Any hints welcome!

Best regards
Andreas

Reply via email to