Siteniz üzerinden gmail'i kullanarak mail gönderin:
PHP- Kodu:
body="Maile gidecek yazı burada olsun"
Dim iMsg, iConf, Flds
Set iMsg = CreateObject("CDO.Message")
Set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields
schema = "http://schemas.microsoft.com/cdo/configuration/"
Flds.Item(schema & "sendusing") = 2
Flds.Item(schema & "smtpserver") = "smtp.gmail.com"
Flds.Item(schema & "smtpserverport") = 465
Flds.Item(schema & "smtpauthenticate") = 1
Flds.Item(schema & "sendusername") = "googlehesabı[email protected]"
Flds.Item(schema & "sendpassword") = "sifren"
Flds.Item(schema & "smtpusessl") = 1
Flds.Update
With iMsg
.To = email
.From = "googlehesabı[email protected]"
.Subject = "Mail konusu"
.HTMLBody = Body 'yukarıdaki body kısmı
.Sender = "[email protected]"
.Organization = "http://www.siteniz.com"
.ReplyTo = "[email protected]"
Set .Configuration = iConf
SendEmailGmail = .Send
End With
Set iMsg = Nothing
Set iConf = Nothing
Set Flds = Nothing
Kendinize göre değiştireceğiniz alanlar:
Flds.Item(schema & "sendusername") = "googlehesabı[email protected]"
Gmail hesabınızı buraya yazın.
Flds.Item(schema & "sendpassword") = "sifren"
Gmail şifrenizi buraya yazın.
Body
Mail alanınız, tavsiye formu oluştururduğunuzda bu alanı kullanabilirsiniz. Örnek:
body="Merhaba,<br /> Arkadaşınız xxx size www.xxx.com/ sayfasını tavsiye etti ..."
.To = request.form("email")
Formdan gelen email değeri burda
.From = "[email protected]"
Gönderdiğiniz mailde gönderen olarak görünen mail adresiniz
.Subject = "Mail konusu"
Mailizin konusu
.HTMLBody = Body
Tanımladığımız mail alanı
.Sender = "[email protected]"
Gönderen mail
.Organization = "http://www.siteniz.com"
Burası gayet açık
.ReplyTo = "[email protected]"
Cevap yazılmasını istediğiniz alan
PHP- Kodu:
body="Maile gidecek yazı burada olsun"
Dim iMsg, iConf, Flds
Set iMsg = CreateObject("CDO.Message")
Set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields
schema = "http://schemas.microsoft.com/cdo/configuration/"
Flds.Item(schema & "sendusing") = 2
Flds.Item(schema & "smtpserver") = "smtp.gmail.com"
Flds.Item(schema & "smtpserverport") = 465
Flds.Item(schema & "smtpauthenticate") = 1
Flds.Item(schema & "sendusername") = "googlehesabı[email protected]"
Flds.Item(schema & "sendpassword") = "sifren"
Flds.Item(schema & "smtpusessl") = 1
Flds.Update
With iMsg
.To = email
.From = "googlehesabı[email protected]"
.Subject = "Mail konusu"
.HTMLBody = Body 'yukarıdaki body kısmı
.Sender = "[email protected]"
.Organization = "http://www.siteniz.com"
.ReplyTo = "[email protected]"
Set .Configuration = iConf
SendEmailGmail = .Send
End With
Set iMsg = Nothing
Set iConf = Nothing
Set Flds = Nothing
Kendinize göre değiştireceğiniz alanlar:
Flds.Item(schema & "sendusername") = "googlehesabı[email protected]"
Gmail hesabınızı buraya yazın.
Flds.Item(schema & "sendpassword") = "sifren"
Gmail şifrenizi buraya yazın.
Body
Mail alanınız, tavsiye formu oluştururduğunuzda bu alanı kullanabilirsiniz. Örnek:
body="Merhaba,<br /> Arkadaşınız xxx size www.xxx.com/ sayfasını tavsiye etti ..."
.To = request.form("email")
Formdan gelen email değeri burda
.From = "[email protected]"
Gönderdiğiniz mailde gönderen olarak görünen mail adresiniz
.Subject = "Mail konusu"
Mailizin konusu
.HTMLBody = Body
Tanımladığımız mail alanı
.Sender = "[email protected]"
Gönderen mail
.Organization = "http://www.siteniz.com"
Burası gayet açık
.ReplyTo = "[email protected]"
Cevap yazılmasını istediğiniz alan