Is there a reason this works in AS1 and not AS2???????
function sendEmail() {
lv = new LoadVars();
new_lv = new LoadVars();
lv.email = email.text;
new_lv.onData = getResponse;
lv.sendAndLoad("emailSubmit.php", new_lv, "POST");
}
function getResponse(success) {
if (success) {
if (this.status == "ok") {
gotoAndStop(2);
} else {
message.text = "Problem";
}
} else {
message.text = "Problem";
}
}
stop();
submit_btn.onRelease = function () {
indexOfAt = email.text.indexOf("@");
lastIndexOfDot = email.text.lastIndexOf(".");
if (indexOfAt != -1 && lastIndexOfDot != -1) {
if (lastIndexOfDot < indexOfAt || indexOfAt == 0) {
message.text = "Verify Email";
} else {
sendEmail();
}
} else {
message.text = "Correct Email";
}
};
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com