function mail_it($content, $subject, $email, $realname, $recipient, $inbound=true) {
global $attachment_chunk, $attachment_name, $attachment_type, $attachment_temp;
global $local_chunk, $local_name, $local_type, $local_temp;
global $bcc, $cc;
global $PHPMailerLocation, $PHPMailerLiteLocation;
global $fixedFromEmail, $fixedFromName, $text_only, $htmlCharset;
if ($realname) {
$sendTo = $realname . "<" . $email . ">";
} else {
$sendTo = $email;
}
$ob = "----=_OuterBoundary_000";
$ib = "----=_InnerBoundery_001";
$mail_headers = "MIME-Version: 1.0\r\n";
if ($fixedFromEmail != '') {
$mail_headers .= "From: " . $fixedFromEmail . "\n";
} else {
$mail_headers .= "From: " . $sendTo . "\n";
}
$mail_headers .= "To: " . $recipient . "\n";
$mail_headers .= "Reply-To: " . $sendTo . "\n";
if ($cc) { $mail_headers .= "Cc: ".$cc."\n"; }
if ($bcc) { $mail_headers .= "Bcc: ".$bcc."\n"; }
$mail_headers .= "X-Priority: 1\n";
$mail_headers .= "X-Mailer: PHPMailer-FE v" . VERSION . " (software by codeworxtech.com)\n";
$mail_headers .= "Content-Type: multipart/mixed;\n\tboundary=\"" . $ob . "\"\n";
$mail_message = "This is a multi-part message in MIME format.\n";
$mail_message .= "\n--".$ob."\n";
$mail_message .= "Content-Type: multipart/alternative;\n\tboundary=\"" . $ib . "\"\n\n";
$mail_message .= "\n--" . $ib . "\n";
$mail_message .= "Content-Type: text/plain;\n\tcharset=\"" . $htmlCharset . "\"\n";
$mail_message .= "Content-Transfer-Encoding: quoted-printable\n\n";
$mail_message .= $content["text"] . "\n\n";
$mail_message .= "\n--" . $ib . "--\n";
/**
* Used as the charset for HTML emails
* default is "iso-8859-1"
* @var string
* NOTE: Required here, change as needed
*/
$htmlCharset = "iso-8859-1";
ASKER
PHP is a widely-used server-side scripting language especially suited for web development, powering tens of millions of sites from Facebook to personal WordPress blogs. PHP is often paired with the MySQL relational database, but includes support for most other mainstream databases. By utilizing different Server APIs, PHP can work on many different web servers as a server-side scripting language.
TRUSTED BY
Open in new window
Taken from: http://php.net/manual/en/function.htmlentities.php