Ive got an asp page setup where people send cause for concerns to relevant people.
However as well as the designated email addresses been used i also want relevant heads of department
to receive the request dependent upon the department the staff member sending the request comes from.
Ive got a htm page with a form on and a drop down list with depts to choose (Art, Business Studies etc)
How do i code it so that when the person filling out the form selects Art for example it sends an email to the
head of art, o r Business Studies to the head of business studies etc???? Ive used this code in the confirmation
asp page:
Code:
<%
Dim myCDONTSMail
Dim strFrom
Dim strTo
Dim strSubject
Dim strBody
strFrom=Request.Form("MyEmail")
strTo="me@wickersley.net, them@wickersley.net,"
strSubject = "Cause for Concern"
strBody="The following information was submitted regarding an Cause for Concern:" & Chr(13)
strBody = strBody & Chr(13) & "Student Name: "
strBody= strBody & Request.Form("studentname") & Chr(13)
strBody = strBody & "Teacher Name: "
strBody= strBody & Request.Form("teachername") & Chr(13)
strBody = strBody & "Teacher Email: "
strBody= strBody & Request.Form("MyEmail") & Chr(13)
strBody = strBody & "Teachers Department: "
strBody= strBody & Request.Form("department") & Chr(13)
strBody = strBody & "Date of Incident: "
strBody= strBody & Request.Form("MyDate") & Chr(13)
strBody = strBody & "Time of Incident: "
strBody= strBody & Request.Form("time") & Chr(13)
strBody = strBody & "Details of Incident: "
strBody= strBody & Request.Form("incidentdetails") & Chr(13)
strBody = strBody & "Did the incident involve ICT?: "
strBody= strBody & Request.Form("ICT") & Chr(13)
Set myCDONTSMail = CreateObject("CDONTS.NewMail")
myCDONTSMail.Send strFrom,strTo,strSubject,strBody
Set myCDONTSMail = Nothing
%>
Hope this makes sense - any help appreciated!
Woody
|