function smtpSession($host, $port = "25", $user = null, $pass = null) { $this->info["host"] = $host; $this->info["port"] = $port ? $port : "25"; $this->info["user"] = $user; $this->info["pass"] = $pass; if (class_exists("conf")) { $this->info["from-mail"] = conf::getkey("core", "site.contact_mail"); $this->info["from-name"] = conf::getkey("core", "site.contact_mail"); } else { // if you're using this file outside Gekko $this->info["from-mail"] = GEKKO_SMTP_FROM_EMAIL; $this->info["from-name"] = GEKKO_SMTP_FROM_NAME; } return $this->connect(); }