PHP mail() function returning false, but with no error

后端 未结 6 2032
傲寒
傲寒 2020-12-11 16:24

I am using php\'s mail() function for the simple process of E-Mailing the input of a contact form to the respective person. The strange thing is that the form always used to

6条回答
  •  爱一瞬间的悲伤
    2020-12-11 17:19

    Check if web is allowed to send mail by giving getsebool httpd_can_sendmail from terminal. If the output is

    httpd_can_sendmail --> off
    

    give https the permission for sending mail by issuing setsebool httpd_can_sendmail 1 command. You must have root permission for issuing these commands.

提交回复
热议问题