Ejemplo n.º 1
0
function emailFormSubmission()
{
    $to = '*****@*****.**';
    $subject = 'Заказ Небесные фонарики Сердце';
    $message = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><title>' . htmlentities($subject, ENT_COMPAT, 'UTF-8') . '</title></head>';
    $message .= '<body style="background-color: #ffffff; color: #000000; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: 18px; font-family: helvetica, arial, verdana, sans-serif;">';
    $message .= '<h2 style="background-color: #eeeeee;">Контактные данные</h2><table cellspacing="0" cellpadding="0" width="100%" style="background-color: #ffffff;">';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Имя:</b></td><td>' . htmlentities($_REQUEST["custom_U824"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    htmlentities($_REQUEST["Email"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Количество:</b></td><td>' . htmlentities($_REQUEST["custom_U840"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Сотовый телефон:</b></td><td>' . htmlentities($_REQUEST["custom_U835"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '</table><br/><br/>';
    $message .= '<div style="background-color: #eeeeee; font-size: 10px; line-height: 11px;">Формы, отправленные с веб-сайта: ' . htmlentities($_SERVER["SERVER_NAME"], ENT_COMPAT, 'UTF-8') . '</div>';
    $message .= '<div style="background-color: #eeeeee; font-size: 10px; line-height: 11px;">IP-адрес посетителя: ' . htmlentities($_SERVER["REMOTE_ADDR"], ENT_COMPAT, 'UTF-8') . '</div>';
    $message .= '</body></html>';
    $message = cleanupMessage($message);
    $formEmail = cleanupEmail($_REQUEST['Email']);
    $headers = 'From:  helpit.odessa@gmail.com' . "\r\n" . 'Reply-To: ' . $formEmail . "\r\n" . 'X-Mailer: Adobe Muse 7.4.30 with PHP/' . phpversion() . "\r\n" . 'Content-type: text/html; charset=utf-8' . "\r\n";
    $sent = @mail($to, $subject, $message, $headers);
    if ($sent) {
        echo '{"FormResponse": { "success": true,"redirect":"spasibo.html"}}';
    } else {
        echo '{"MusePHPFormResponse": { "success": false,"error": "Failed to send email"}}';
    }
}
function emailFormSubmission()
{
    $to = '*****@*****.**';
    $subject = 'Cancel Form Submission';
    $message = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><title>' . htmlentities($subject, ENT_COMPAT | ENT_HTML401, 'UTF-8') . '</title></head>';
    $message .= '<body style="background-color: #ffffff; color: #000000; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: 18px; font-family: helvetica, arial, verdana, sans-serif;">';
    $message .= '<h2 style="background-color: #eeeeee;">New Form Submission</h2><table cellspacing="0" cellpadding="0" width="100%" style="background-color: #ffffff;">';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Enter the day:</b></td><td>' . htmlentities($_REQUEST["custom_U1098"], ENT_COMPAT | ENT_HTML401, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Enter the month:</b></td><td>' . htmlentities($_REQUEST["Email"], ENT_COMPAT | ENT_HTML401, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Enter the year:</b></td><td>' . htmlentities($_REQUEST["custom_U1115"], ENT_COMPAT | ENT_HTML401, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Enter The Time Arrival:</b></td><td>' . htmlentities($_REQUEST["custom_U1103"], ENT_COMPAT | ENT_HTML401, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Custom::</b></td><td>' . htmlentities($_REQUEST["custom_U1124"], ENT_COMPAT | ENT_HTML401, 'UTF-8') . '</td></tr>';
    $message .= '</table><br/><br/>';
    $message .= '<div style="background-color: #eeeeee; font-size: 10px; line-height: 11px;">Form submitted from website: ' . htmlentities($_SERVER["SERVER_NAME"], ENT_COMPAT | ENT_HTML401, 'UTF-8') . '</div>';
    $message .= '<div style="background-color: #eeeeee; font-size: 10px; line-height: 11px;">Visitor IP address: ' . htmlentities($_SERVER["REMOTE_ADDR"], ENT_COMPAT | ENT_HTML401, 'UTF-8') . '</div>';
    $message .= '</body></html>';
    $message = cleanupMessage($message);
    $formEmail = cleanupEmail($_REQUEST['Email']);
    $headers = 'From:  mohab_mohamed_20@hotmail.com' . "\r\n" . 'Reply-To: ' . $formEmail . "\r\n" . 'X-Mailer: Adobe Muse 5.0.704 with PHP/' . phpversion() . "\r\n" . 'Content-type: text/html; charset=utf-8' . "\r\n";
    $sent = @mail($to, $subject, $message, $headers);
    if ($sent) {
        echo '{"FormResponse": { "success": true,"redirect":"your-profile.html"}}';
    } else {
        echo '{"MusePHPFormResponse": { "success": false,"error": "Failed to send email"}}';
    }
}
Ejemplo n.º 3
0
function emailFormSubmission()
{
    if (!defined('PHP_EOL')) {
        define('PHP_EOL', '\\r\\n');
    }
    $to = '*****@*****.**';
    $subject = 'Tax Service Muse Template Form Submission';
    $message = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><title>' . htmlentities($subject, ENT_COMPAT, 'UTF-8') . '</title></head>';
    $message .= '<body style="background-color: #ffffff; color: #000000; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: 18px; font-family: helvetica, arial, verdana, sans-serif;">';
    $message .= '<h2 style="background-color: #eeeeee;">New Form Submission</h2><table cellspacing="0" cellpadding="0" width="100%" style="background-color: #ffffff;">';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>GET A FREE CONSULTATION:</b></td><td>' . htmlentities($_REQUEST["custom_U6114"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Email:</b></td><td>' . htmlentities($_REQUEST["Email"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Message:</b></td><td>' . htmlentities($_REQUEST["custom_U6119"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Cell Phone:</b></td><td>' . htmlentities($_REQUEST["custom_U6128"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>Custom:</b></td><td>' . htmlentities($_REQUEST["custom_U6124"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '</table><br/><br/>';
    $message .= '<div style="background-color: #eeeeee; font-size: 10px; line-height: 11px;">Form submitted from website: ' . htmlentities($_SERVER["SERVER_NAME"], ENT_COMPAT, 'UTF-8') . '</div>';
    $message .= '<div style="background-color: #eeeeee; font-size: 10px; line-height: 11px;">Visitor IP address: ' . htmlentities($_SERVER["REMOTE_ADDR"], ENT_COMPAT, 'UTF-8') . '</div>';
    $message .= '</body></html>';
    $message = cleanupMessage($message);
    $formEmail = cleanupEmail($_REQUEST['Email']);
    $headers = 'From: civet520@163.com' . PHP_EOL . 'Reply-To: ' . $formEmail . PHP_EOL . 'X-Mailer: Adobe Muse 2014.0.328 with PHP/' . phpversion() . '/' . PHP_OS . PHP_EOL . 'Content-type: text/html; charset=utf-8' . PHP_EOL;
    $sent = @mail($to, $subject, $message, $headers);
    if ($sent) {
        echo '{"FormResponse": { "success": true}}';
    } else {
        echo '{"MusePHPFormResponse": { "success": false,"error": "Failed to send email"}}';
    }
}
Ejemplo n.º 4
0
function emailFormSubmission()
{
    $to = '';
    $subject = 'Contact表單 送出';
    $message = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><title>' . htmlentities($subject, ENT_COMPAT, 'UTF-8') . '</title></head>';
    $message .= '<body style="background-color: #ffffff; color: #000000; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: 18px; font-family: helvetica, arial, verdana, sans-serif;">';
    $message .= '<h2 style="background-color: #eeeeee;">新的表單送出</h2><table cellspacing="0" cellpadding="0" width="100%" style="background-color: #ffffff;">';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>名稱:</b></td><td>' . htmlentities($_REQUEST["custom_U1117"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>電子郵件:</b></td><td>' . htmlentities($_REQUEST["Email"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '<tr><td valign="top" style="background-color: #ffffff;"><b>訊息:</b></td><td>' . htmlentities($_REQUEST["custom_U1122"], ENT_COMPAT, 'UTF-8') . '</td></tr>';
    $message .= '</table><br/><br/>';
    $message .= '<div style="background-color: #eeeeee; font-size: 10px; line-height: 11px;">表單由此網站送出: ' . htmlentities($_SERVER["SERVER_NAME"], ENT_COMPAT, 'UTF-8') . '</div>';
    $message .= '<div style="background-color: #eeeeee; font-size: 10px; line-height: 11px;">訪客 IP 位址: ' . htmlentities($_SERVER["REMOTE_ADDR"], ENT_COMPAT, 'UTF-8') . '</div>';
    $message .= '</body></html>';
    $message = cleanupMessage($message);
    $formEmail = cleanupEmail($_REQUEST['Email']);
    $headers = 'From:  ' . "\r\n" . 'Reply-To: ' . $formEmail . "\r\n" . 'X-Mailer: Adobe Muse 7.0.314 with PHP/' . phpversion() . "\r\n" . 'Content-type: text/html; charset=utf-8' . "\r\n";
    $sent = @mail($to, $subject, $message, $headers);
    if ($sent) {
        echo '{"FormResponse": { "success": true}}';
    } else {
        echo '{"MusePHPFormResponse": { "success": false,"error": "Failed to send email"}}';
    }
}