Send mail not working on php 7.4 or higher

Hi.
I changed the php version from 7.3 to 7.4 on the server and the contact form using ‘mailer / send mail’ stopped working.
It doesn’t work with version 8.0 either.
In order to use it, I had to restore the 7.3 version indicated as ‘obsolete’.
The server reports error 500.
Any idea to solve this?

Community Page
Last updated: