Groups | Blog | Home
all groups > flash actionscript > september 2007 >

flash actionscript : Flash Actionscript to generate php form information



Mary Alice
9/4/2007 10:29:28 PM
I created a form in Flash 8 professional. I made the background of the form a
movie clip. Then place static text for: name, address, city-state-zip, phone,
email and comments. Then placed Flash text input rectangles next to each of
those static text.
Below the comments, I placed Flash Button and named it SUBMIT and to the right
of that a button named Reset.

Now, I need a simple Flash Actionscript to generate .php so 'all form
information' will come to my email.

I believe I put that Actionscript in my SUBMIT button and another Actionscript
in my Reset button.
I need help on the Actionscrippt to generate php.

MaryAlice
art.design@comcast.net
clbeech
9/4/2007 10:37:02 PM
AS can't 'generate' php, but you can send the variables to a server-side php
script that can then generate the email and send it to you. You will need to
use the LoadVars class to send the variables tot he php doc. But you will need
to write the php seperate from the AS Flash file.

give me a few minutes and I'll prepare some sample code.
clbeech
9/5/2007 12:05:57 AM
OK, here's some basic example files for both the codes for the AS using
LoadVars, and the PHP to generate an email response, there are comments in the
codes that will tell you what's happening and what you need to change to make
it work for you. You will need to mount the PHP file on your server after
having made the necessary changes, before it will work for testing:
http://www.beechstudios.com/send_email.zip

good luck :)
AddThis Social Bookmark Button