SendMail
|
|
|
|
| FlashStore rating: |
Not rated yet.
|
| User rating: |
|
| Date: |
13-11-06 |
| Submited by: |
danyb |
| Skill: |
advanced |
| Price: |
$ 25.00 |
|
|
| |
About |
SendMail is a component that can be used to send emails from you flash applications without any server side scripting knowledge. Its easy to use, and from the properties panel you can set the send button, the event message field, the text input from where the SendMail component will extract the data needed for sending emails, etc.
We offer you also the PHP and ASP script that the component uses to send emails. The path for the script can be set from the properties panel.
A flash demo (contact form) is attached in the zip file with the component.
|
UI Access |
| Components |
Support address |
|
|
Code samples |
Parameters:
butSend:String the button that is clicked to send email
errorEmailField:String error text for invalid email
errorMessageField:String error text for the message field
errorMessageSent:String error text for message not sent
errorNameField:String - error text for name field
errorServerConnection:String - error text for server connection error
errorServerScript:String - error text for server script error
errorSubjectField:String - error text for subject field
fromEmailInput:String the from email text input
fromNameInput:String the from name text input
isRequiredFromName:Boolean true if from name is required
isRequiredMessage:Boolean true if message is required
isRequiredSubject:Boolean true if subject is required
messageHandler:String the message text imput for displaying events
messageInput:String the email message text input
scriptPath:String the script path used to send emails (PHP or ASP)
subjectInput:String the email subject text input
textMessageSent:String the text for message sent
toEmail:String email address where the mails will be sent
Methods
send(fromName, fromEmail, subject, message) send email function
Events
onSend email sent event
onSendError send email error event
onServerConnectionError error while trying to connect to the server
onServerScriptError server script error
Code samples:
this.attachMovie("SendMail", "sendMailComp", this.getNextHighestDepth(), {_x:250, _y:200});
sendMailComp.butSend = _root.smMC.smButSend;
sendMailComp.errorEmailField = 'Error: Invalid email!';
sendMailComp.errorMessageField = 'Error: Please fill in the message field';
sendMailComp.errorMessageSent = 'Error: Message not sent!';
sendMailComp.errorNameField = 'Error: Please fill in the from name field!';
sendMailComp.errorServerConnection = 'Error: Server connection error!';
sendMailComp.errorServerScript = 'Error: Server script error!';
sendMailComp.errorSubjectField = 'Error: Please fill in the subject field';
sendMailComp.fromEmailInput = '_root.smMC.smFromEmailInput';
sendMailComp.fromNameInput = '_root.smMC.smFromNameInput';
sendMailComp.isRequiredFromName = false;
sendMailComp.isRequiredMessage = true;
sendMailComp.isRequiredSubject = true;
sendMailComp.messageHandler = '_root.smMC.smMessageHandler';
sendMailComp.messageInput = '_root.smMC.smMessageInput';
sendMailComp.scriptPath = 'sendmail.php';
sendMailComp.subjectInput = '_root.smMC.smSubjectInput';
sendMailComp.textMessageSent = 'Message sent';
sendMailComp.toEmail = 'youremail@yourdomain.com';
var oListener:Object = new Object();
oListener.onSend = function(oEvent:Object):Void {
trace('email sent');
};
oListener.onSendError = function(oEvent:Object):Void {
trace('send error');
};
oListener.onServerConnectionError = function(oEvent:Object):Void {
trace("Error connecting to server.");
};
oListener.onServerScriptError = function(oEvent:Object):Void {
trace("Server script error.");
};
sendMailComp.addEventListener("onSend", oListener);
sendMailComp.addEventListener("onSendError", oListener);
sendMailComp.addEventListener("onServerConnectionError", oListener);
sendMailComp.addEventListener("onServerScriptError", oListener);
|
Features |
| included |
|
|
|
|
|