phpDocumentor VFront
Authentication
[ class tree: VFront ] [ index: VFront ] [ all elements ]

Source for file auth.soap.php

Documentation is available at auth.soap.php

  1. <?php
  2. /**
  3.  * @package VFront
  4.  * @subpackage Authentication
  5.  * @author Mario Marcello Verona <marcelloverona@gmail.com>
  6.  * @copyright 2007 Mario Marcello Verona
  7.  * @version 0.90
  8.  * @license http://www.gnu.org/licenses/gpl.html GNU Public License
  9.  * @see auth
  10.  * 
  11.  */
  12.  
  13.  
  14.  
  15.  
  16.     /**
  17.      * Funzione sperimentale di autenticazione tramite SOAP
  18.      * Viene richiamata dalla classe {@link auth}
  19.      *
  20.      * @param string $user Nome utente
  21.      * @param string $passw Password
  22.      * @return array 
  23.      */
  24.     function auth_soap($user$passw){
  25.         
  26.         global $conf_auth;
  27.  
  28.         
  29.         $client new SoapClient($conf_auth['soap']['wsdl']array(
  30.                 'soap_version' => SOAP_1_1,
  31.                 "trace"      => 1,
  32.                 "exceptions" => 0)
  33.                
  34.                );
  35.             
  36.             $GetUser $client2->$conf_auth['soap']['function_get_user'](array($conf_auth['campo_email']=>$user,$conf_auth['campo_password']=>$passw));
  37.             
  38.             
  39.             if(isset($GetUser->$conf_auth['ldap']['function_get_user_results'])){
  40.     
  41.                 $parametri[$conf_auth['campo_email']] $GetUser->GetUserResult->$conf_auth['campo_email'];
  42.                 $parametri[$conf_auth['campo_nome']] $GetUser->GetUserResult->$conf_auth['campo_nome'];
  43.                 $parametri[$conf_auth['campo_cognome']] $GetUser->GetUserResult->$conf_auth['campo_cognome'];
  44.                 
  45.                 
  46.                 return array('response'=>true,$parametri);
  47.             }
  48.             else{
  49.                 return array('response'=>false,$parametri);
  50.             }
  51.             
  52.         
  53.         }
  54.         
  55.  
  56. ?>

Documentation generated on Sat, 22 Sep 2007 11:49:53 +0200 by phpDocumentor 1.4.0a2