|
-
Using Flash and Coldfusion to send email
The following email.cfm file is used to recieve the data from flash 8:
<cfif StructKeyExists(Form, "emailFrom")>
<cfmail
to="[email protected]"
from="#Form.emailFrom#"
subject="Jules Artistry Contact From"
>
#Form.From#<br>
#Form.emailFrom#<br>
#Form.emailPhone#<br>
<br>
#Form.emailBody#
</cfmail>
&result=true
<cfelse>
&result=false
</cfif>
The following code is used on the timeline in Flash:
this.submit_btn.onRelease = function() {
var emailResponse:LoadVars = new LoadVars();
emailResponse.onLoad = function(success:Boolean) {
if (success) {
debug_txt.text = this.result;
} else {
debug_txt.text = "error downloading content";
}
};
var email:LoadVars = new LoadVars();
email.emailFrom = emailFrom_txt.text;
email.From = From_txt.text;
email.emailPhone = emailPhone_txt.text;
email.emailBody = emailBody_txt.text;
email.sendAndLoad("http://rickclark.com/jules/email.cfm", emailResponse, "POST");
};
Both files were uploaded to my Coldfusion server. Unfortunately, nothing happens. when I click on the submit button. Can anyone help me save what little hair I have left?
Thanks,
Rick
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|