예제 #1
0
 function onStartCommand(StackDataStore $login)
 {
     $fields = $login->getHierarchy();
     $this->resourceIndex = @mysqli_connect($fields[self::DB_SERVER], $fields[self::DB_USERNAME], $fields[self::DB_PASSWORD]);
     if (!$this->resourceIndex) {
         return false;
     }
     return true;
 }
예제 #2
0
 function onStartCommand(StackDataStore $login)
 {
     $fields = $login->getHierarchy();
     if (!$fields[self::DB_USE_EXTRAS]) {
         $this->resourceIndex = new \SQLite3($fields[self::DB_FILE]);
     } else {
         $this->resourceIndex = new \SQLite3($fields[self::DB_FILE], $fields[self::DB_OPTIONS], $fields[self::DB_ENCRYPT_KEY]);
     }
     return true;
 }