* finish task #2618.
This commit is contained in:
@@ -58,12 +58,14 @@ class mail extends control
|
||||
{
|
||||
if($_POST)
|
||||
{
|
||||
set_time_limit(30);
|
||||
$error = '';
|
||||
if($this->post->fromAddress == false) $error = sprintf($this->lang->error->notempty, $this->lang->mail->fromAddress);
|
||||
if(!validater::checkEmail($this->post->fromAddress)) $error .= '\n' . sprintf($this->lang->error->email, $this->lang->mail->fromAddress);
|
||||
|
||||
if($error) die(js::alert($error));
|
||||
|
||||
echo "<script>setTimeout(function(){parent.location.href='" . inlink('edit') . "'}, 10000)</script>";
|
||||
$mailConfig = $this->mail->autoDetect($this->post->fromAddress);
|
||||
$mailConfig->fromAddress = $this->post->fromAddress;
|
||||
$this->session->set('mailConfig', $mailConfig);
|
||||
|
||||
@@ -144,6 +144,7 @@ class mailModel extends model
|
||||
if(!$connection) return false;
|
||||
fclose($connection);
|
||||
|
||||
$config = new stdclass();
|
||||
$config->username = $username;
|
||||
$config->host = $host;
|
||||
$config->auth = 1;
|
||||
|
||||
Reference in New Issue
Block a user