%
If Request.querystring("upload") <> "" Then
Dim objUpload
Dim strFileName
Dim strPath
Dim FileLength
Server.ScriptTimeout = 5400
' Instantiate Upload Class
Set objUpload = New clsUpload
' Grab the file name
strFileName = objUpload.Fields("File1").FileName
FileLength = ObjUpload.Fields("File1").Length
If FileLength > 256000 then
' Release upload object from memory
Set objUpload = Nothing
session("msg") = "Göndermeye çalıştığınız dosyanın büyüklüğü 250KB 'dan Büyük ...!
Zipleyiniz veya küçültünüz.
Dosyanız : " & strFileName & "
Dosya Büyüklüğü : " & FileLength
session("uploadedfilename")=""
response.Redirect("form.asp?success=false")
End if
' Compile path to save file to
strPath = Server.MapPath("../dosyalar/" & strFileName)
' Save the binary data to the file system
objUpload("File1").SaveAs strPath
' Release upload object from memory
Set objUpload = Nothing
session("msg") = "Dosyanız ("& strFileName &") alınmıştır. Aşağıdakı forma da açıklamanızı yazınız."
session("uploadedfilename") = strPath
End If
If Request.querystring("Send") <> "" Then
msg_txt = "Hizmetofisi İletişim Formu"
msg_txt = msg_txt & "
adiniz: " & Request.form("adiniz")
msg_txt = msg_txt & "
eposta: " & Request.form("eposta")
msg_txt = msg_txt & "
tel: " & Request.form("tel")
msg_txt = msg_txt & "
fax: " & Request.form("fax")
msg_txt = msg_txt & "
icq:
" & Request.form("icq")
msg_txt = msg_txt & "
msn:
" & Request.form("msn")
msg_txt = msg_txt & "
web:
" & Request.form("web")
msg_txt = msg_txt & "
talep:
" & Request.form("talep")
msg_txt = msg_txt & "
detay:
" & Request.form("detay")
msg_txt = msg_txt & "
Originating-IP:
" & Request.ServerVariables("REMOTE_ADDR")
msg_txt = msg_txt & ""
%>
<%
session("msg") = ""
Set Mail = Server.CreateObject("Persits.MailSender")
Mail.Host = "mail.hizmetofisi.com"
Mail.From = Request.form("eposta")
Mail.FromName = Request.form("adiniz")
Mail.AddBCC "info@hizmetofisi.com"
Mail.AddBCC "arm@kablonet.com.tr"
Mail.AddAddress Request.form("eposta")
If Not session("uploadedfilename")="" then
Mail.AddAttachment session("uploadedfilename")
End If
Mail.Subject = "İletişim Formu"
Mail.IsHTML = True
Mail.Body = msg_txt
Mail.AddCustomHeader "Originating-IP: " & Request.ServerVariables("REMOTE_ADDR")
On Error Resume Next
Mail.Send
If Err <> 0 Then
msg = "Mesajınız Gönderilemedi.
" & Err.Description
else
msg = "Mesajınız Alınmıştır Teşekkur ederiz.Hizmetofisi."
session("uploadedfilename") = ""
End If
End If
%>
| İLETİŞİM FORMU <%=msg%> |
||