當前位置: 首頁>>代碼示例>>PHP>>正文


PHP SoapClient::updateUser方法代碼示例

本文整理匯總了PHP中SoapClient::updateUser方法的典型用法代碼示例。如果您正苦於以下問題:PHP SoapClient::updateUser方法的具體用法?PHP SoapClient::updateUser怎麽用?PHP SoapClient::updateUser使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在SoapClient的用法示例。


在下文中一共展示了SoapClient::updateUser方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: updateProfile

 /**
  * Update profile
  * 
  * @return Response
  */
 public function updateProfile()
 {
     $session = Session::get('user');
     $userService = new SoapClient(Config::get('wsdl.user'), array());
     $geoService = new SoapClient(Config::get('wsdl.utility'), array());
     $currentUser = $userService->getUserByEmail(array('email' => $session['data']->email))->user;
     $currentUser->businessName = Input::get('businessName');
     $currentUser->about = Input::get('about');
     $currentUser->address = $geoService->getAddressByZipcode(array("zipcode" => Input::get('zipCode')))->address;
     $currentUser->website = Input::get('website');
     $currentUser->contactName = Input::get('contactName');
     $currentUser->contactNumber = Input::get('contactNumber');
     $currentUser->email = Input::get('email');
     try {
         $userService->updateUser(array('user' => $currentUser));
     } catch (Exception $ex) {
     }
 }
開發者ID:Yatko,項目名稱:Gifteng,代碼行數:23,代碼來源:BizController.php

示例2: profile

 public function profile()
 {
     $file = Input::file('uploader');
     $destinationPath = app_path() . '/storage/uploads/';
     $filename = $file->getClientOriginalName();
     Input::file('uploader')->move($destinationPath, $filename);
     $image = ImageModel::createImageModel($filename);
     try {
         $session = Session::get('user');
         $userService = new SoapClient(Config::get('wsdl.user'));
         $currentUser = $userService->getUserById(array("userId" => $session['data']->id));
         $currentUser = $currentUser->user;
         $currentUser->avatar = $image;
         $result = $userService->updateUser(array("user" => $currentUser));
         return Response::json($result->complete);
     } catch (Exception $ex) {
     }
 }
開發者ID:Yatko,項目名稱:Gifteng,代碼行數:18,代碼來源:ImageController.php

示例3: updateProfile

 /**
  * Update profile
  * 
  * @return Response
  */
 public function updateProfile()
 {
     $session = Session::get('user');
     $userService = new SoapClient(Config::get('wsdl.user'), array());
     $geoService = new SoapClient(Config::get('wsdl.utility'), array());
     $currentUser = $userService->getUserByEmail(array('email' => $session['data']->email))->user;
     if (!$currentUser->address) {
         $address = new Address();
     } else {
         $address = new Address($currentUser->address);
     }
     $currentUser->firstName = Input::get('first_name');
     $currentUser->lastName = Input::get('last_name');
     $currentUser->about = Input::get('about');
     if (Input::get('zipCode')) {
         $address = $geoService->getAddressByZipcode(array("zipcode" => Input::get('zipCode')));
         $currentUser->address = $address->address;
     } else {
         if (Input::get('zipCode') == "") {
             $currentUser->address = new Address();
         }
     }
     try {
         $userService->updateUser(array('user' => $currentUser));
     } catch (Exception $ex) {
     }
 }
開發者ID:Yatko,項目名稱:Gifteng,代碼行數:32,代碼來源:UserController.php

示例4: array

<?php

// client
$options = array('location' => 'http://localhost/soap/user.php', 'uri' => 'http://localhost/soap/');
// $client=new SoapClient("user.wsdl");
$client = new SoapClient("http://localhost/soap/user.php?wsdl");
// var_dump($client->register('Goh','aasd','goh.puayhiang@Outlook.com',''));
// var_dump($client->login('goh.puayhiang@Outlook.com','aasd',''));
// var_dump($client->activateAccount('goh.puayhiang@Outlook.com','24419'));
// var_dump($client->recaptchaKey());
$temp = array("Name" => "Puay Hiang", "Email" => "gph004@yahoo.com.sg", "Password" => "asd");
//,"Password"=>"Hello"
$Email = "gph004@yahoo.com.sg";
$Password = "asd";
$SessionKey = $client->login($Email, $Password, "asd")[1];
echo $SessionKey;
var_dump($client->updateUser(json_encode($temp), $Password, $SessionKey));
開發者ID:GPHofficial,項目名稱:urimg,代碼行數:17,代碼來源:soaptest.php

示例5: destroy

 /**
  * Delete store
  * 
  * @return Response
  */
 public function destroy($id)
 {
     $session = Session::get('user');
     $userService = new SoapClient(Config::get('wsdl.user'), array());
     $currentUser = $userService->getUserByEmail(array('email' => $session['data']->email))->user;
     if (is_object($currentUser->addresses)) {
         $currentUser->addresses = array($currentUser->addresses);
     }
     $addresses = $currentUser->addresses;
     foreach ($addresses as $k => $val) {
         if ($val->id == $id) {
             $val->deleted = true;
             $addresses[$k] = $val;
         }
     }
     $currentUser->addresses = $addresses;
     try {
         $userService->updateUser(array('user' => $currentUser));
     } catch (Exception $ex) {
     }
 }
開發者ID:Yatko,項目名稱:Gifteng,代碼行數:26,代碼來源:StoreController.php

示例6: out

function out($str)
{
    echo $str . "\n";
}
ini_set('soap.wsdl_cache_enabled', 0);
$username = 'admin';
//$_POST['username'];
$password = 'secret';
//md5($_POST['password']);
//$client = new SoapClient("https://srvfh13.fh-luebeck.de/moodle/moodleplugin.wsdl",array('trace'=>1,'login'=>$username,'password'=>$password));
$client = new SoapClient("https://www.myserver.com/moodle/moodleplugin.wsdl");
try {
    $sessid = '';
    out($sessid = $client->login($username, $password));
    out($client->addUser($sessid, 'testheinz', '1234', 'Heinz', 'Test', 'anonymous@somewhere.de'));
    out($client->updateUser($sessid, 'testheinz', 'Heinzi', 'Tester', 'someone@somewhere.de'));
    out($sessid = $client->logout($sessid));
    out($client->deleteUser($sessid, 'testheinz'));
    //echo $client->exportUsers(2, 'CF101');
    //echo $client->importCourses($xml_string,"Prova");
    //echo $client->exportCourses();
    //echo $client->exportCourses(3,"Prova");
    //echo $client->exportCategories();
} catch (SoapFault $sf) {
    //echo $client->__getLastRequest();
    echo $client->__getLastResponse();
    echo $sf->faultstring;
}
/*else
	{
		if (empty($_SERVER[HTTPS])) {
開發者ID:BackupTheBerlios,項目名稱:moodlews-svn,代碼行數:31,代碼來源:clientsoap.php


注:本文中的SoapClient::updateUser方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。