function setOptions($options) { parent::setOptions($options); $this->connections = array(); // Opening connections. foreach ($options as $conn => $spec) { $this->connections[$conn] = new \PDO($spec['dsn'], $spec['username'], $spec['password'], @$spec['options']); } }
function setOptions($options) { parent::setOptions($options); $this->default_sender = @$options['sender']; $classname = "\\assegai\\modules\\mail\\services\\Builtin"; if (isset($options['service'])) { // We use the standard email service if (class_exists($options['service']) && in_array('assegai\\modules\\mail\\Service', class_implements($options['service']))) { $classname = $options['service']; } else { $classname = "\\assegai\\modules\\mail\\services\\" . ucwords($options['service']); } } $this->svc = new $classname(@$options['options']); }