Αρχή :: Ενότητες :: Scripting :: Απαντήσεις     
 

Forum

FORM - Από {elina}

FORM


Γεια σας και ΧΡΟΝΙΑ ΠΟΛΛΑ!
Εχω δυο φορμες απο τις οποιες οταν ο χρηστης κανει submit θελω να μου ερχονται στο email οι απαντισεις. Το site ειναι σε windows και η εταιρεια hosting υποστηριζει το cdonts (καλα μεχρι εδω).Εχω τη φορμα στην οποια ειναι και η ρουτινα αλλα...Μπερδευομαι σε μερικα σημεια τι θα βαλω...που
ο κωδικας ειναι:
strAuthorEmail - Το email του αποστολέα
'| strRecipientEmail - Το email του αποδέκτη
'| strCC - To email του 2ου αποδέκτη (αν υπάρχει)
'| strSubject - Το θέμα του email
'| [ strBody ] - Το κυρίως μέρος του email
'| intMailFormat - To είδος του email [ 0 = HTML / 1 - Text ]
'| [ strAttachmentPath ] - Διαδρομή δίσκου για επισυναπτόμενο αρχέιο (προαιρετικό)
'|
'| intPriority - Προτεραιότητα
'| CdoHigh = 2 - Highest priority (Urgent)
'| CdoNormal = 1 - Normal
'| CdoLow = 0 - Lowest
'| Παράδειγμα κλήσης της ρουτίνας :
'| Call EmailCdonts("webmaster@somewhere.com",Recipient,"", "Subject",strBody ,0,"",2)

Function EmailCdonts(byval strAuthorEmail,byval strRecipientEmail,ByVal strCC, byval strSubject,byval strBody,
ByVal intMailFormat,ByVal strAttachmentPath,ByVal intPriority)
Dim ObjMail

'-----------------------[ START ERROR CHECKING ]---------------------------
If strAuthorEmail = "" or isnull(strAuthorEmail) Then
Response.Write("The author email parameter is missing")
Response.End
End If

If strRecipientEmail = "" or isnull(strRecipientEmail) Then
Response.Write("The Recipients email parameter is missing")
Response.End
End If

If strSubject = "" or isnull(strSubject) Then
Response.Write("The Subject parameter is missing")
Response.End
End If

If intMailFormat = "" or isnull(intMailFormat) Then
Response.Write("The Email Type parameter is missing, [ 0 = HTML / 1 - Text ] - Required Paramter")
Response.End
End If

'-----------------------[ END ERROR CHECKING ]---------------------------

Set ObjMail = Server.CreateObject("CDONTS.NewMail")

ObjMail.FROM = strAuthorEmail
ObjMail.TO = strRecipientEmail

If strCC <> "" Then
ObjMail.Cc = strCC
End If


ObjMail.Subject = strSubject

ObjMail.BodyFormat = intMailFormat
ObjMail.MailFormat = intMailFormat
ObjMail.Body = strBody

' CdoHigh = 2 - Highest priority (Urgent)
' CdoNormal = 1 - Normal
' CdoLow = 0 - Lowest
ObjMail.Importance = intPriority


If strAttachmentPath <> "" Then
ObjMail.AttachFile strAttachmentPath
End If

ObjMail.Send

Set ObjMail= Nothing

End Function
%>
Παρακαλω με παραδειγμα δικων σας για πχ στοιχεια για να καταλαβω........
...Mesa stis parenteseis. THANKS ANY...

 


Απάντηση από:Alex

Εσύ θα αλλάξεις μόνο τις 2 πρώτες σειρές

Όπως
strAuthorEmail - Το email του αποστολέα
'| strRecipientEmail - Το email του αποδέκτη

σε

strAuthorEmail – info@to_domain_sou.com
strRecipientEmail - info@to_domain_sou.com

Απάντηση από:elina

EYXARISTW Alex, apla mperdeytika giato an oi allages tha gin



tip: Μην γκρινιάζεις για το παρελθόν . Δες ώστε το μέλλον να είναι καλύτερο . * F5 για νέο tip

   Πίσω στην προηγούμενη σελίδα






Η Εταιρία | Web Hosting | Domain names | Web Information | Υπηρεσίες | Resellers | Υποστήριξη |
Copyright © 2007–09 4GR.NETWORKS, All rights reserved.