X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=reporting%2Fincludes%2Fclass.mail.inc;h=edda2b5ad781e077ae28816802b8ef00fa8a6512;hb=b0c4c9777f9574e9c2805fddc2a12576d75d94ce;hp=65066ca75fa8eb75ca4cbad1d3f6eaacc145f68e;hpb=264c09696d65efe4532c197f317162daf8c24f32;p=fa-stable.git diff --git a/reporting/includes/class.mail.inc b/reporting/includes/class.mail.inc index 65066ca7..edda2b5a 100644 --- a/reporting/includes/class.mail.inc +++ b/reporting/includes/class.mail.inc @@ -39,11 +39,15 @@ class email var $subject = ""; var $body = ""; var $charset = 'ISO-8859-1'; + var $add_params; function email($name, $mail) { $this->boundary = md5(uniqid(time())); $this->header = "From: $name <$mail>\n"; + $bcc = get_company_pref('bcc_email'); + if ($bcc) + $this->bcc[] = $bcc; } function to($mail) @@ -132,9 +136,7 @@ class email } $this->header .= "\n"; } - $this->header .= "MIME-Version: 1.0\n"; $this->header .= "Content-Type: multipart/mixed;\n boundary=\"$this->boundary\"\n"; - $this->header .= "This is a multi-part message in MIME format.\n"; // Attachment hinzufügen $max = count($this->attachment); @@ -156,10 +158,9 @@ class email $ret = 0; foreach($this->to as $mail) { - if (mail($mail, $this->subject, $this->body, $this->header)) + if (mail($mail, $this->subject, $this->body, $this->header, $this->add_params)) $ret++; } return $ret; } } -?> \ No newline at end of file