AWS PHPMailer - send mail from form

Job ID: 34301626

Budget: $15 – $25 USD

I coded a 2-page webform that captures data and inserts into AWS MySQL database. That works fine! Also, I created some DB tables and stored procedures to assign the task to users based on fewest amount of tasks. That works fine!

After inserting the data and having the task assigned to a user, I need to send an email message to the person that filled out the form (To) and (From) the person that was assigned the task.

If I use AWS' Send_Email_SMTP.php and enter my host, smtp username and password, the email is sent when I specify the recipient, sender, subject and body, but I need it to be dynamic and pull from the database.

There are 3 schema files attached:

crm_users - lists the internal id, username and their email address - these are the only fields in need from this table.

whp - lists the data from the web forms that a potential client enters. I need the following fields from this (wpbestp_home_purchase) table:
fName, lName, assigned_to, property_state, lead_status