| version 1.4, 2005/11/07 18:33:18 |
version 1.5, 2005/11/26 11:49:41 |
|
|
| * http://platon.sk/projects/Metafox/ |
* http://platon.sk/projects/Metafox/ |
| */ |
*/ |
| |
|
| /* $Platon: Metafox/functions.inc.php,v 1.3 2005/10/31 05:42:51 nepto Exp $ */ |
/* $Platon: Metafox/functions.inc.php,v 1.4 2005/11/07 18:33:18 nepto Exp $ */ |
| |
|
| /* |
/* |
| * Line wrap function |
* Line wrap function |
| Line 705 function ezin_email_template_parse($mess |
|
| Line 705 function ezin_email_template_parse($mess |
|
| return $message; |
return $message; |
| } /* }}} */ |
} /* }}} */ |
| |
|
| // DELETE ME IN SPRING 2005 |
|
| function ezin_email_send_old($emails, $from, $subject, $encoding, $message) /* {{{ */ |
|
| { |
|
| global $ezin_cfg; |
|
| $message .= "\n\n--\n"; |
|
| $message .= "Metafox - enterprise content management system\n"; |
|
| $message .= 'http://platon.sk/projects/Metafox/'; |
|
| empty($from) && $from = sprintf('"Metafox on %s" <webmaster@%s>', $ezin_cfg['name'], $_SERVER['SERVER_NAME']); |
|
| empty($subject) && $subject = sprintf('%s issues', $ezin_cfg['name']); |
|
| empty($encoding) && $encoding = $ezin_cfg['encoding']; |
|
| empty($encoding) && $encoding = 'iso-8859-1'; |
|
| $headers = array( |
|
| 'MIME-Version: 1.0', |
|
| 'Content-type: text/plain; charset='.$encoding, |
|
| 'Content-transfer-encoding: 8bit', |
|
| 'Date: '.gmdate('D, d M Y H:i:s', time()).' UT', |
|
| 'From: '.$from); |
|
| $headers = join("\n", $headers); |
|
| if (! is_array($emails)) { |
|
| $emails = preg_split('|\s+|', $emails); |
|
| } |
|
| $ret = true; |
|
| foreach ((array) $emails as $email) { |
|
| $email = trim($email); |
|
| if (empty($email) || strpos($email, '@') === false) { |
|
| continue; |
|
| } |
|
| $ret &= @mail($email, $subject, $message, $headers); |
|
| } |
|
| return $ret; |
|
| } /* }}} */ |
|
| |
|
| function ezin_email_send($emails, $from, $subject, $encoding, $message) /* {{{ */ |
function ezin_email_send($emails, $from, $subject, $encoding, $message) /* {{{ */ |
| { |
{ |
| global $ezin_cfg, $ezin_sys; |
global $ezin_cfg, $ezin_sys; |