-
I tried loadvars..
this code doesn't work..
I tried
v.send("Email.aspx?from="+from+"&email="+email+"&s ubject="+subject+"&message="+ message);
before I had v.from = from; but this didn't work so I tried the above code.. didn't work..
Essentially, I would like to have a flash site and when you click then it sends to the server but without refreshing, opening new browser, etc...
Thank you..
-
President, save the New Zealand dollar foundation
Code:
v = new LoadVars();
v.from = _root.fromText.text;
v.email = _root.emailtext.text;
v.subject = _root.subjectText.text;
v.message = _root.messageText.text;
v.onLoad = function(success) { // to handle data returned (no new page)
if (success) {
trace("data sent successfully";
} else {
trace("unsuccessful");
}
}
v.sendAndLoad("Email.aspx?from="+from+"&email="+email+"&subject="+subject+"&message="+message", v, "POST");
where _root."whatever"Text are your input textfields.
-
Thank you~
seems to work great.
couple of more questions...
when does success return false?
and is there any way to have no new page without doing sendAndLoad ? (this question is just out of curiosity)
-
President, save the New Zealand dollar foundation
success should return false, if there is an error on the server side, like an application error, or you send a value that asp isn't expecting....
no page? not sure without testing it,
try using just send() and see what happens...
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
|