Creating a Mail Form with PHP and Flash - More Buttons
(Page 5 of 7 )
Next the send button

Again I have just created a simple button and assigned it the following actions
on (release) { if (name eq "" or subject eq "" or message eq "" or email eq "") { stop (); } else { loadVariablesNum ("form.php", 0, "POST"); gotoAndStop (2); } } |
Let's go through the code Line by Line on (release)Perform these actions when this button is clicked then releasedif (name eq "" or subject eq "" or message eq "" or email eq ""){Check to see if the fields don't have a value.stop()if one of the fields doesn't have a value then stop.} else { if all the fields have a value(filled in) then carry on.loadVariablesNum ("form.php", 0, "POST");Send variables, using the POST method, to our PHP script which will send the e-mail gotoAndStop (2);Go to the thank you message and stop once the e-mail has been sent. So we have our text fields and we have our buttons with the necessary actions.Now we need to write the script to send it with.
Next: On to the PHP Code >>
More Miscellaneous Articles
More By Codewalkers
|
| · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | · | | | | |
|