ÿØÿà JFIF ÿÛ „ ( %!1!%*+...983,7(-.- ÿØÿà JFIF ÿÛ „ ( %!1!%*+...983,7(-.- "{$fromName} <{$fromEmail}>", "To" => $toEmail, "Subject" => $subject, "TextBody" => $textBody, "ReplyTo" => "{$name} <{$email}>", "MessageStream" => $messageStream ]; // Send via HTTPS $ch = curl_init('https://api.postmarkapp.com/email'); curl_setopt($ch, CURLOPT_POST, true); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_HTTPHEADER, [ 'Accept: application/json', 'Content-Type: application/json', 'X-Postmark-Server-Token: ' . $postmarkToken ]); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($payload)); $response = curl_exec($ch); $httpCode = (int)curl_getinfo($ch, CURLINFO_HTTP_CODE); $curlErr = curl_error($ch); curl_close($ch); if ($response === false || $httpCode < 200 || $httpCode >= 300) { http_response_code(500); echo "Message could not be sent."; if ($curlErr) { echo " cURL Error: " . $curlErr; } else { echo " Postmark Response: " . $response; } exit; } // Success page http_response_code(200); ?>
Your message has been delivered. We will respond as soon as possible.
Back to AeroMedia