webservices = $config->webservices->toArray(); } public function getInfosLogin($login, $ipUtilisateur = ''){ $params = new stdClass(); $params->login = $login; $params->ipUtilisateur = $ipUtilisateur; $client = $this->loadClient('interne'); $reponse = $client->getInfosLogin($params); return $reponse->getInfosLoginResult; } protected function loadClient($webservice){ $wsdl = $this->webservices[$webservice]['wsdl']; $options = $this->webservices[$webservice]['options']; $auth = Zend_Auth::getInstance(); $login = $auth->getIdentity()->username; $hash = md5($login.'|'.$auth->getIdentity()->password); $options['login'] = $login; $options['password'] = $hash; $client = new SoapClient($wsdl, $options); return $client; } }