0

So I'm a bit confused and need direction.

I am building a website which contains a "Contact Us" page.

I host this site using nginx as the web server and has sendmail as an MTA.

The confusion is whether or not a mail server is needed or do I just do everything through nginx.

I set up the contact us page and used php's mail() funciton and got back false. As in nothing was sent. After asking for help some gent told me to pass the arguments to sendmail. After further reseach, I found that sendmail is used by command line only. If this is the case, then there's no point in using sendmail for the "Contact Us" page.

I don't want to set up a mail server to use for personal use, just to send email messages from the website to a gmail account....ok maybe just forward that message to a gmail account.

Would someone please some me understand this concept.

Brad
  • 23
  • 5
  • Have you checked mail() function logs in `/var/log/exim4/mainlog`? keep in mind that you need proper hostname and spf records w/ dkim to not get marked as spam. alternatively you can use phpmailer for sending email, just use your gmail's own SMTP server to send mail to yourself, https://stackoverflow.com/questions/712392/send-email-using-the-gmail-smtp-server-from-a-php-page?rq=1 – SiddheshNan Jun 10 '19 at 11:29
  • Thanks for the reply. I will look into the logs and and check out spf records w/ dkim to understand those terms. – Brad Jun 10 '19 at 15:09

0 Answers0