示例#1
0
文件: Ldap.php 项目: visapi/amun
 public function __construct($container)
 {
     parent::__construct($container);
     $this->res = ldap_connect(self::LDAP_HOST);
     if (!$this->res) {
         throw new Exception('Ldap connection failed');
     }
     if (!ldap_bind($this->res, self::USER_DN, self::USER_PW)) {
         throw new Exception('Could not bind Ldap');
     }
 }
示例#2
0
文件: Openid.php 项目: visapi/amun
 public function __construct($container)
 {
     parent::__construct($container);
     $this->http = $container->get('http');
     $this->store = new Store\Sql($this->sql, $this->registry['table.core_assoc']);
 }
示例#3
0
文件: Twitter.php 项目: visapi/amun
 public function __construct($container)
 {
     parent::__construct($container);
     $this->http = $container->get('http');
     $this->oauth = new Oauth($this->http);
 }