Is there a way I can configure automatic e-mails to be sent when new data is added to a MySQL database. Preferably in PHP.
The idea is that when new information is submitted to the DB an e-mail is automatically generated containing the new information with a link to view the information online and sent to a pre-configured e-mail address.
The purpose of this is for a leave booking system. Colleagues will be able to submit dates and times of leave and the team manager is automatically informed as and when they are added or changed.
I have tried using Word Press but it is far too clunky and a lot more powerful than I need. I have also noted another couple of questions here on Stack Flow but they have no responses or answers and not strictly the same question.
Any help would be greatly appreciated.
If you have an SMTP service running, you can outfile to the drop directory. If you have high volume, you may result with duplicate file names, but there are ways to avoid that.
Otherwise, you will need to create a UDF.
Here’s a sample trigger solution:
To markup the message body you will need something like this…