I use PHP to send mail on Fedora 36.
mail($email, $betreff, $content, $header);
However the mail does not arrive. What could be the problem?
Check if php successfully transfers responsibility for email delivery.
if (mail($to, $subject, $message, $headers)) {
echo 'email was sent.';
} else {
echo 'An error occurred.';
}
On Linux/Unix php by default sends emails via local MTA/SMTP server.
Check/report which MTA is installed on your system (postfix/sendmail/exim/…).