mirror of
https://github.com/myronblair/tomsjavajive
synced 2026-06-30 17:50:32 -05:00
Fix CyberMail payload format: use flat string for from/to fields
This commit is contained in:
@@ -336,8 +336,7 @@ function sendEmail($to, $subject, $htmlContent, $textContent = '') {
|
||||
error_log('[TJJ sendEmail] CYBERMAIL_API_KEY not configured');
|
||||
return false;
|
||||
}
|
||||
$payload = ['from' => ['email' => $from, 'name' => $fromName],
|
||||
'to' => [['email' => $to]], 'subject' => $subject, 'html' => $htmlContent];
|
||||
$payload = ['from' => $from, 'to' => $to, 'subject' => $subject, 'html' => $htmlContent];
|
||||
if ($textContent) $payload['text'] = $textContent;
|
||||
$ch = curl_init('https://platform.cyberpersons.com/email/v1/send');
|
||||
curl_setopt_array($ch, [
|
||||
|
||||
Reference in New Issue
Block a user