Candidate Application
Helping to find the right job for you
<%if request.QueryString("a")=1 then%>
<%Dim oFileUp
Set oFileUp = Server.CreateObject("SoftArtisans.FileUp")
oFileUp.Path = Server.MapPath("/upload")
If Not oFileUp.Form("cv").IsEmpty Then
oFileUp.Form("cv").Save
timestamp=""
set fso = CreateObject("Scripting.FileSystemObject")
'fso.MoveFile "E:\kunden\homepages\32\d106467299\live\bandl\upload\"&oFileUp.Form("cv").ShortFileName,"E:\kunden\homepages\32\d106467299\live\bandl\upload\"&oFileUp.Form("surname")&oFileUp.Form("firstname")&"_"&oFileUp.Form("cv").ShortFileName
set f=fso.GetFile("E:\kunden\homepages\32\d106467299\live\bandl\upload\"&oFileUp.Form("cv").ShortFileName)
f.Copy "E:\kunden\homepages\32\d106467299\live\bandl\upload\"&oFileUp.Form("surname")&oFileUp.Form("firstname")&"_"&oFileUp.Form("cv").ShortFileName,true
f.Delete
set fso = Nothing
'Response.Write(oFileUp.Form("myFile").ServerName)
'Response.Write(oFileUp.Form("cv").ShortFileName)
Else
'Response.Write("Error: There was no file submitted for upload.")
End If
%>
<%Set fs=Server.CreateObject("Scripting.FileSystemObject")
Set f=fs.OpenTextFile(Server.MapPath("emailtemplate.asp"), 1)
emailtemplate=f.ReadAll
f.Close
Set f=Nothing
Set fs=Nothing%>
<%
emailtemplate=replace(emailtemplate,"
position",oFileUp.Form("position"))
emailtemplate=replace(emailtemplate,"
jobtitle",oFileUp.Form("jobtitle"))
emailtemplate=replace(emailtemplate,"
vacancy",oFileUp.Form("vacancy"))
emailtemplate=replace(emailtemplate,"
presentsalery",oFileUp.Form("presentsalery"))
emailtemplate=replace(emailtemplate,"
presentemployer",oFileUp.Form("presentemployer"))
emailtemplate=replace(emailtemplate,"
surname",oFileUp.Form("surname"))
emailtemplate=replace(emailtemplate,"
firstname",oFileUp.Form("firstname"))
emailtemplate=replace(emailtemplate,"
address",oFileUp.Form("address"))
emailtemplate=replace(emailtemplate,"
telephonehome",oFileUp.Form("telephonehome"))
emailtemplate=replace(emailtemplate,"
convictions",oFileUp.Form("convictions") & ": " & oFileUp.Form("convictiondetails"))
emailtemplate=replace(emailtemplate,"
drivinglicence",oFileUp.Form("drivinglicence"))
emailtemplate=replace(emailtemplate,"
drivingendorsements",oFileUp.Form("drivingendorsements"))
emailtemplate=replace(emailtemplate,"
disability",oFileUp.Form("disability"))
emailtemplate=replace(emailtemplate,"
outsideinterests",oFileUp.Form("outsideinterests"))
emailtemplate=replace(emailtemplate,"
education",oFileUp.Form("education"))
emailtemplate=replace(emailtemplate,"
qualifications",oFileUp.Form("qualifications"))
emailtemplate=replace(emailtemplate,"
dateemployed",oFileUp.Form("dateemployed"))
emailtemplate=replace(emailtemplate,"
companyemployed",oFileUp.Form("companyemployed"))
emailtemplate=replace(emailtemplate,"
businesstypeemployed",oFileUp.Form("businesstypeemployed"))
emailtemplate=replace(emailtemplate,"
jobtitleemployed",oFileUp.Form("jobtitleemployed"))
emailtemplate=replace(emailtemplate,"
duties",oFileUp.Form("duties"))
emailtemplate=replace(emailtemplate,"
achievements",oFileUp.Form("achievements"))
emailtemplate=replace(emailtemplate,"
finalsalery",oFileUp.Form("finalsalery"))
emailtemplate=replace(emailtemplate,"
reasonforleaving",oFileUp.Form("reasonforleaving"))
emailtemplate=replace(emailtemplate,"
1dateemployed",oFileUp.Form("1dateemployed"))
emailtemplate=replace(emailtemplate,"
1companyemployed",oFileUp.Form("1companyemployed"))
emailtemplate=replace(emailtemplate,"
1businesstypeemployed",oFileUp.Form("1businesstypeemployed"))
emailtemplate=replace(emailtemplate,"
1jobtitleemployed",oFileUp.Form("1jobtitleemployed"))
emailtemplate=replace(emailtemplate,"
1duties",oFileUp.Form("1duties"))
emailtemplate=replace(emailtemplate,"
1achievements",oFileUp.Form("1achievements"))
emailtemplate=replace(emailtemplate,"
1finalsalery",oFileUp.Form("1finalsalery"))
emailtemplate=replace(emailtemplate,"
1reasonforleaving",oFileUp.Form("1reasonforleaving"))
emailtemplate=replace(emailtemplate,"
2dateemployed",oFileUp.Form("2dateemployed"))
emailtemplate=replace(emailtemplate,"
2companyemployed",oFileUp.Form("2companyemployed"))
emailtemplate=replace(emailtemplate,"
2businesstypeemployed",oFileUp.Form("2businesstypeemployed"))
emailtemplate=replace(emailtemplate,"
2jobtitleemployed",oFileUp.Form("2jobtitleemployed"))
emailtemplate=replace(emailtemplate,"
2duties",oFileUp.Form("2duties"))
emailtemplate=replace(emailtemplate,"
2achievements",oFileUp.Form("2achievements"))
emailtemplate=replace(emailtemplate,"
2finalsalery",oFileUp.Form("2finalsalery"))
emailtemplate=replace(emailtemplate,"
2reasonforleaving",oFileUp.Form("2reasonforleaving"))
emailtemplate=replace(emailtemplate,"
additional",oFileUp.Form("additional"))
emailtemplate=replace(emailtemplate,"
references",oFileUp.Form("references"))
emailtemplate=replace(emailtemplate,"
cv","
"&oFileUp.Form("surname")&oFileUp.Form("firstname")&"_"&oFileUp.Form("cv").ShortFileName&"")
emailtemplate=replace(emailtemplate,"
iagree",oFileUp.Form("iagree"))
emailtemplate=replace(emailtemplate,"
iagree",oFileUp.Form("iagree"))
emailtemplate=replace(emailtemplate,"..style1 {",".style1 {")
emailtemplate=replace(emailtemplate,"..style2 {",".style2 {")
%>
<%
Set oSendMailer = Server.CreateObject("SMTPsvg.Mailer")
oSendMailer.FromAddress = "mailer@bandlrecruitment.com"
oSendMailer.FromName = "FromName"
oSendMailer.AddRecipient "Charles", "charles@planetearthlogistics.com"
oSendMailer.AddRecipient "Heather", "heather@bandlrecruitment.com"
oSendMailer.RemoteHost = "smtp.1and1.com"
oSendMailer.Subject = "(BandL - Candidate Application) - " & oFileUp.Form("firstname") & oFileUp.Form("surname")
oSendMailer.ContentType="Text/HTML"
oSendMailer.BodyText = emailtemplate
oSendMailer.SendMail
set oSendMailer = nothing
%>
<%
'strPath = Server.MapPath(".")
'Set mailer = Server.CreateObject("SoftArtisans.SMTPMail")
'strVer = Mailer.Version
'mailer.RemoteHost = "smtp.1and1.com"
'mailer.FromAddress = "mailer@bandlrecruitment.com"
'mailer.AddRecipient "Charles", "charles@planetearthlogistics.com"
'mailer.AddRecipient "Charles", "radion_auto@hotmail.com"
'mailer.HTMLText = emailtemplate
'mailer.Subject = "(BandL - Candidate Application) - " & oFileUp.Form("firstname") & oFileUp.Form("surname")
'If mailer.SendMail then
'Response.Write "Mail sent."
'Else
'Response.Write "Mail failure."
'End If
'response.write mailer.response
'set mailer = nothing
'Set oFileUp = Nothing
%>
Thank you for your application, We will normally get in touch within 2 working days.
<%else%>
<%end if%>