Flash Forms And Simple If Else Condition
I created a Flash form for users to fill out. When the form is submitted they leave the movie. I want to return users back to a specific frame in the flash movie after the form has been submitted.
I have control over the redirect URL after the form submits and I can dynamically provide variables in an ASP file.
The variables print properly in a dynamic text box so I know the values are coming across.
I tried to solve my problem by pulling variables from an ASP file and then using those values to take the user to the thank you page or the primary content. If var0 = 1 then take them to the thank you page, else take them back to the primary content. The way I am doing it below doesn't work...
Any suggestions?
loadVariablesNum ("variables.asp", 0); if (var0 = 1) { gotoAndPlay (10); stop (); } else { gotoAndPlay (5); stop (); }
FlashKit > Flash Help > Flash ActionScript
Posted on: 07-29-2002, 12:53 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Flash Forms And Simple If Else Condition
I created a Flash form for users to fill out. When the form is submitted they leave the movie. I want to return users back to a specific frame in the flash movie after the form has been submitted.
I have control over the redirect URL after the form submits and I can dynamically provide variables in an ASP file.
The variables print properly in a dynamic text box so I know the values are coming across.
I tried to solve my problem by pulling variables from an ASP file and then using those values to take the user to the thank you page or the primary content. If var0 = 1 then take them to the thank you page, else take them back to the primary content. The way I am doing it below doesn't work...
Any suggestions?
loadVariablesNum ("variables.asp", 0);
if (var0 = 1) {
gotoAndPlay (10);
stop ();
} else {
gotoAndPlay (5);
stop ();
}
Simple Forms Not Working On Flash 8?
Hello,
i'm trying to make a simple form, using the old but effective tutorials scattered around... I've developed forms successfuly in the past, but now the same procedures doesn't seem to work.. the strange thing is that the source files of the tutorials work, but my application doesn't; to be more precise, it works, but the mail i'm receiving back is blank, just the strings declared in the PHP file; tracing within flash, the loadVars object contains all the correct data, but somewhere in the road it gets lost. Does anybody knows the answer for this problem? I know almost nothing of PHP
Here's the code I've got (based upon a tutorial by CyanBlue)
ActionScript Code:
_global.sndMail = function(hasta) {
var pqte = new LoadVars();
for (i=1; i<=hasta; i++) {
var nTemp = tsp["c"+i].ct.text;
pqte[nTemp] = tsp["i"+i].text;
}
pqte.onLoad = function(ok) {
if (ok) {
trace("Email Sent!!!");
} else {
trace("Problem sending an Email!!!");
}
};
pqte.sendAndLoad("form.php", pqte, "POST");
};
tracing unescape(pqte) yields this
PHP Code:
");
}
}
else
{
echo("This script runs only in Flash!!!");
}
?>
=&");
}
else
{
echo("=&result=2&<?php
if ($_POST)
{
$mailTo = "berrios@instrumental.cl";
$mailSubject = "[Contact] Website Contact from - (" . $_POST['NOMBRE'] . ")";
$Header = "MIME-Version: 1.0
";
$Header .= "Content-type: text/html; charset=iso-8859-1
";
$Header .= "From: " . $_POST['E-MAIL'] . "
";
$output = "<BR>";
$output .= "De : " . $_POST['NOMBRE'] . "<BR><BR>";
$output .= "e-mail : " . $_POST['E-MAIL'] . "<BR><BR>";
$output .= "comentario : " . $_POST['comentario'] . "<BR><BR>";
$output = nl2br($output);
if (e-mail($mailTo, $mailSubject, stripslashes($output), $Header))
{
echo("&onLoad=[type Function]&COMENTARIO=HERE I WROTE MY COMMENT&EMPRESA=HERE I WROTE MY COMPANY NAME&E-MAIL=HERE I WROTE MY E-MAIL&NOMBRE=HERE I WROTE MY NAME
Email Sent!!!
The text is sent with all caps, so i tried to change some variables to all caps and others not for testing purposes... i didn't add the "company" field because the example php file had only three fields, wanted them to work before changing more things around...
Thanks in advance,
Sir Patroclo
Anyone Had Experience With Forms And Flash? Simple Problem I Think
hello friends,
i've created a flash form that im using to send four variables to a php script.. I am having some trouble sending the
variables to the script.. In fact, i cant get it to work at all.
I have created the file
http://members.optushome.com.au/panus/flash.swf
The drop down buttons are set in the movie mode which i think is correct, along with the submit button.
I looked up what action script I should use but found many different ones. I tested a couple of them out but they don't
seem to submit anything at all, the submit button isn't functioning. It's like the submit button isnt attaching itself
to the values of the drop down buttons, and then not submitting..
I tried using
On (Release)
Load Variables ("mailto:form.php", 1, vars=POST)
End On
I'm pretty new to flash and was hoping for a little help.
the flash file is located here if you want to have a look
http://members.optushome.com.au/panus/flash.fla
regards
-n
Help With A Simple Condition Please
Hey all,
Fantastic help i get from here, thanks very much.
I have a small problem which i am sure will be easy to solve but not for me lol
One of my movie buttons are controlled like this:
Code:
// Takes effect when the mouse has moved over the object.
this.leaflet_mc.onRollOver = function() {
leaflet_mc.gotoAndPlay("_over")
}
// Takes effect when the mouse has moved away from the object.
this.leaflet_mc.onRollOut = function() {
leaflet_mc.gotoAndPlay("_out");
}
// Takes effect when the mouse has clicked the object.
this.leaflet_mc.onPress = function() {
_root.containerl.loadMovie("leaflet.swf");
}
Now what is happening is i hover over the object and it animates as it should which is great and when i move off the object the animation starts to stop which it also should so top marks there but.... what i dont like is that once i move off the object and the animation starts to stop, if i hover over it again it makes the animation play the onRollOver again but whilst the movie is in this state i do not want it to do so.
In a nutshell if i move away from the object i do not want it to recognise the onRollOver until the animation has finished for the onRollOut.
Please help :-) Thanks you
A Simple Doubt On If Condition.
I am a pure beginner in scripting.
I just want to move a movie clip towards the X position. when its reaches a specific point, the movement should be in opposite direction. like the value of X should be negative.
I am trying this code. but the ball movement will stopped on the first reaching point. it is not coming backward. I know this is a kid's play for you. But I am desperately trying for this.. Please help me..
my code on the movieclip is:
onClipEvent (enterFrame) {
devi = 5;
this._x+= devi;
//trace (_x);
if (this._x>400) {
this._x-= devi;
}
}
Help me Pleeeeeeeeease............ !
Some Help For A Simple Condition Statement...
Hello! I wanted some help this condition statement...
There are 2 tweens called "mc_sun" and "mc_welcome" I want to run when someone clicks on a button called "btn_home", but I don't know exactly how to write the code because I've already tried these 2 modes and noone work at all!
THANKS FOR THE HELP!!!!
Attach Code
In this one, both tweens run but I have to double click the button "btn_home" so the 2nd tween runs.
btn_home.onPress = function () {
if(mc_sun._y == 700) {
new Tween(mc_sun,"_y",Regular.easeOut,startY,startY-200,16 ,false);
}
if(mc_sun._y == 500) {
mc_welcome.play();
}
}
And in this one, where I placed the 2nd "if statement" into the 1st one, doesn't work, what can I do if I want that both tweens run when someone clicks just ONCE on the button "btn_home"??????
btn_home.onRelease = function () {
if(mc_sun._y == 700) {
new Tween(mc_sun,"_y",Regular.easeOut,startY,startY-209,16 ,false);
if(mc_sun._y == 500) {
mc_welcome.play();
}
}
}
Flash "forms" Behavior - Simple Main Frame Sim
I have a Flash object that is emulating a main frame application. I have the user tab to a particular spot, enter a value, and if the value is correct, I send the user to another frame in the object. If the value is not correct, the user is alerted and directed to correct the entered value.
The actionscript involved uses text objects which listen for values; once anything at all is entered in the target text area, the last of 4, the focus shifts to a hidden button. The button is supposed to respond to the user striking ENTER by testing the value of the text area and responding accordingly.
The problem: although the button receives the focus, it does not respond to the ENTER key. The code for the button and the text area are below (the text and the button are in the same layer).
Button code:
PHP Code:
on (release, keyPress "<Enter>") {
// assign text entered to variable for testing
newPathCEc = text4_CE26c_var;
if (newPathCEc == "S") {
//jump to next frame, frame 10
gotoAndStop(10);
} else {
loadMovieNum("../images/feedback_incorrect_daace26c.swf", 4);
}
}
Code for textbox:
PHP Code:
stop();
//set focus on first text area
Selection.setFocus(text1_CE26c);
inputButton_CE26c._focusrect = false;
unloadMovieNum(4);
inputButton_CE26c._focusrect = false;
//prevent text in all but the last test region, allowing all to receive the tabbed cursor
text1_CE26c.restrict = " ^A-Z 0-9";
text2_CE26c.restrict = " ^A-Z 0-9";
text3_CE26c.restrict = " ^A-Z 0-9";
text4_CE26c.restrict = " A-Z";
text1_CE26c.tabIndex = 1;
text2_CE26c.tabIndex = 2;
text3_CE26c.tabIndex = 3;
text4_CE26c.tabIndex = 4;
//code to direct tabbing action so user moves through subsequent text areas
increment = 0;
keyListener1_CE26c = new Object();
Key.addListener(keyListener1_CE26c);
keyListener1_CE26c.onKeyDown = function() {
a = Key.getCode();
if (a == 40 || a == 9) {
next = increment++;
Selection.setFocus("text"+next+"_CE26c");
//Selection.removeListener(textboxListener);
}
};
// send focus to hidden button if the user types anything into the last text region
textListener4_CE26c = new Object();
text4_CE26c.addListener(textListener4_CE26c);
textListener4_CE26c.onChanged = function() {
if (text4_CE26c.length == 1) {
Selection.setFocus(inputButton_CE26c);
//trace("I've changed");
Selection.removeListener(textListener4_CE26c);
}
};
Simple Forms
Can anyone help? I am working my way through the simple form tutorial, and I am stuck on the section where I attach script to the send button. The last two commands, "End if" and "End on" dont appear to there to select. I am using Flash 5, has this changed in the update from 4 to 5?
If anyone could help it would be fantastic.
Thanks
Alan
Simple Forms
I am only a beginner so i dont know, but can i make a form in flash that users can type into and then send it directly to my email account with out the use of C.G.I
Obviously components would come into it somewhere.
This Should Be A Simple On (more On Forms...)
Flash MX 2004 Professional (latest update applied)
I'm sure all you gurus out there are absolutely sick of reading flash form questions ... probably just as sick as I am of reading tutorials that I just can't get to work.
I am redesigning my new site completely in Flash (with an html-based sidekick site for dialup users). On the html site, I can easily get the small form to work - not so much luck in flash. I need to be able to pass form data (just a text input and combo box along with 2 static 'variables') to a php script and I simply cannot get it to work. This is a simple domain registration form. Nothing fancy, no validation ... The required elements (per html) are:
<form method="post" action="https://domain.com/billing/order/orderwiz.php">
// -------my two static entries that need to be passed------- \
<input type="hidden" name="v" value="1">
<input type="hidden" name="submit_domain" value="register">
// -------domain name from user input (text input)------- \
<input type="text" name="domain" value="">
// -------my combo box options------- \
<select name="tld_extension">
<option value="com">.com</option>
<option value="net">.net</option>
<option value="org">.org</option>
<option value="info">.info</option>
<option value="biz">.biz</option>
<option value="us">.us</option>
</select>
<input type="submit" name="submit" value="Go!">
</form>
I would like this to send the user and his variables to the php page. I would post what I have tried, but I would like to see a fresh start on this instead of trying to fix my poorly written code. Find the format that I have been working with below (all previous AS stripped out) (please keep reponses simple and stupid - kinda the way I feel right now ) Your help is greatly appreciated
Download layout fla here.
Converting Html Forms To Flash Forms?
i'm in the middle of creating a website for a record company. i've been doing it all in flash, so when they asked me to set up a newsletter facility, i decided it would be in flash. here's my problem:
the host i'm using has a newsletter add/remove facility in html. i've tried converting this into flash but it just wont work! the html form code provided by the hoist (which does work) is below:
<form action='http://cp.cyberstation.co.uk/list.cgi' method='post'>
<input type='hidden' name='list' value='Newsletter'/>
<input type='hidden' name='redirect-success' value='http://www.mickhayglaziers.co.uk/complete.html'/>
<b>Our Mailing List</b><br/>
<input type='text' name='email'/><br/>
<input class='radio' type='radio' name='action' value='add' checked='checked'/>Subscribe
<input class='radio' type='radio' name='action' value='delete'/>Unsubscribe<br/>
<input type='submit' value='Do it Now!'/>
</form>
The actionscript i used on the submit button when converted is:
on (release) {
list="Newsletter";
action="add";
loadVariablesNum ("http://cp.cyberstation.co.uk/list.cgi", "0", "Post");
}
The button is also, along with the list and action variables, on the main timeline!
can anyone offer any insight to where i'm going wrong?
Simple Forms To Email
I am trying to create a simple web page with 2 input text fields at the bottom for users to input a company name and donation amount. I have these created in flash mx2004 version 7 but I don't know what actions to attach to them to have the information users input transferred to an email address. Any help would be appreciated.
Shannon
Looking For A Tutorial On Simple Forms
I am looking for a tutorial that will introduce me to setting up a simple feedback form in Flash MX and that hopefully covers sending the gathered user input to FormMail.
The tutorials I have seen so far, seem to concentrate on radio buttons, combo boxes, check boxes, styling, etc., as opposed to text boxes and textareas and how to send results somewhere.
Any suggestions?
A Few Questions In Regards To Forms: Simple
Stop animation repeating:
-if i want to fade my form using an alpha of 0% starting out then 10 frames later fade to 100% alpha, then how do i make it so it doesnt repeat itself? instead do it once as the form is loaded.
text component trouble:
i have text fields im using as input text fields. a tutorial that i learned from told me to start out by making a button and place the text in the up frame. this way when i drag the text button onto the frame i can fade it and do other things as its a symbol..
Problem
doing this i end up with TWO instance names, one on the button symbol and one when i drag it onto the scene. which one am i using? also in the code am i making my own variable or am i using the one i specified in the button scene
i put my questions down below
PHP Code:
function onSubmit()
{
// Initialize form variables:
formData = new LoadVars();
//ok so is this a variable i make up now or am i using the one i gave to the text box button?
formData.name = "";
// Get textbox info:
//is txtname the instance name of the textbox? if so which instance name? the one on the scene or the button
formData.name = txtname.getValue();
last question:
do i put the code in the frame/scene rather than the actualy submit button?
Simple Question About Referencing Forms
I have what I hope is a simple question. Could someone please provide a primer on how to reference forms (and things contained in forms) in AS2? Specifically, I am having trouble referencing a form loaded into another form. Here is my form structure:
Application
Form1
Form2
Loaded into Form1 is an swf containing another set of forms, with this structure:
NewApplication
NewForm1
NewForm2
So, how do I reference NewForm1 from Application and vice versa?
Thanks.
-Brian
"if" Simple Condition Not Working
I need that a movieclip plays and when it reaches the end frame, where I placed a stop, some other clip do something else.
I came up with this code, but is not working, not even the trace thing.
Sure is somethig stupid I'm missing... any help?
Code:
on(release){
_root.mc_central.mask_animate.gotoAndPlay ("2");
if (_root.mc_central.mask_animate._currentframe == 16)
{
_root.mc_central.gotoAndPlay ("recursos");
trace ("funciona");
}
}
Flash 5: GotoAnd Play Condition
Hello,
In the condition statement below, the code executes and jumps to the specified frame 20 in mc2, and stops there. However, it should continue to the next frame since I have no stop() command on frame 20. After entering mc2, I'm trying to get the play head to run to frame 30 - playing animations between frames 20-30.
gotoAndPlay executes if using a button event. Could it be the condition statement or the fact that the movie are also using the attachMovie method?
Thank You
iaustin
onClipEvent(load){
var a = getTimer();
var countdown = 6000;//6 sec
var c = 0;
}
onClipEvent(enterFrame){
b = getTimer();
c = (b - a);
//condition
if (c <= countdown){
_root.mc2.gotoAndStop(_currentFrame);
}else{
_root.mc2.gotoAndPlay(20);
}
}
Email Forms, Feedback Forms
I have posted the same topic on the other section but i thought perhaps this one would be more appropiate?
I need help with creating a feedback forms (name, phone nubmer, email, comments etc) in a flash site.
I have d/n a CGI script that comes with the tutorial in Flash Kit. and I also found a PHP scripts that i was told it should do the same thing.
I am new to BOTH, CGI or PHP whatever,
After i read the CGI mail form tutorial , it seems like i need to link the button to cgi-bin/whatever.cgi right? How about PHP? Questions is DO i just paste the PHP code in the action windows of flash MX or place the code in a html page that creates a seperate window?
What is easier for newbees like me and is there any easier approprach?
__________________
*!* I really need some help *!*
Forms, Nested Forms, And Masks?
Is there a way to provide a mask that applies to nested slides and forms? I have a structure that looks like this:
Form1
Slide1
SubSlide1
SubSlide2
SubSlide3
SubSlide4
SubSlide5
SubForm1
SubForm2
The app starts and shows Slide1 containing a background provided by Form1 then based on button rollovers the sub slides show with a nice fade transition. This all works GREAT.
When the button is clicked the selected SubForm1 or SubForm2 screens (which contain separate swf files) is displayed with a left to right “fly in” transition while the Slide1 is hidden with a right to left “fly out” transition. Now again this works great except for the fact that I need a mask so that the user does not see the SubForms flying from outside the bounds of Form1.
I have tried applying masks to ALL forms and subforms with no success (including the masks to forms in the external swf files on the SubForms.) Is there a way to make this work or do I have to use a loader component to make the mask work the way I want?
Thanks,
R. Sparrow
Forms On Flash
Hi! i am making a website on flash and i want to know how to use forms in flash! can you use a CGI script? if so how!
PLEASE PLEASE HELP ME!!!!!!!!!!!!!!!!!!!!!!!!
ICE
Flash Forms
Hello,
does anyone know how to create a flash button that allows a user to attach a file to an email form. The form validation and processing is handled by ASP, i dont know if this makes any difference???
Cheers
D
Forms In Flash
My question is, is it possible to design forms and have the infomation sent to an email adress when the form is completed. I know how to go about doing this with regualr html forms but how do i go about doing it in flash. Please let me know of all the coding that must be used or directing me to a website that has a tutoial about it.
Mark
Forms In Flash
Do I need to use cgi/perl to submit a form to an email address? Someone told me to just put your email address, but other people say that this will not work for people using aol or compuserve. I'd like to use a form, especially since flash makes them look better than the default browser ones.
thanks.
Forms In Flash
Hello all,
Does anyone know the best way to send information using a form in flash. I am trying to avoid using a FormMail script. I know in some applications you can send the information in an email without using any script at all. Is there any way to do this in Flash 5???
Any help is appreciated.
Forms In Flash
Me again,
This is my problem: A client is using Netscape 4.7. I am trying to send a form using a CGI script and it works (kind of) in IE and Netscape 4.7. The problem is the script wants to open a new window after submitting the information. Is there a way to keep this window from opening?? I have tried a "redirect" but no luck in Netscape. It just opens a new window with the beginning of the flash movie.
Is there any way that I can send this form without using a CGI script?? I know in some applications you can send the information in an email without using a script at all. Is this possible in Flash??
Here is the url to the site.
http://www.odessatex.com/test/
click "available sites" to get to the form. All the fields are required except work phone.
Here is the script I am using as well.
on (release) {
recipient = "my_email_address";
subject = "online_information";
if (name eq "") {
gotoAndStop ("sorry", 1);
} else if (company eq "") {
gotoAndStop ("sorry", 1);
} else if (address eq "") {
gotoAndStop ("sorry", 1);
} else if (city eq "") {
gotoAndStop ("sorry", 1);
} else if (state eq "") {
gotoAndStop ("sorry", 1);
} else if (zip_code eq "") {
gotoAndStop ("sorry", 1);
} else if (email eq "") {
gotoAndStop ("sorry", 1);
} else {
getURL ("http://my_script_url", "_blank", "GET");
gotoAndStop ("for_sale", 1);
}
}
Thanks in advance.
Forms In Flash?
How do I get forms to work in flash? I would like to have the button send the info to my cgi program, and still remain on the same page, and if for some reason the cgi program has an error that it send the info to flash. Is that possible?
I plan on doing form validation in flash before though, but it wont catch everything. I'm guessing the best way to do forms is to use getURL and use POST and send it to a popup window. Is this correct? Any ideas, tips, etc?
Forms And Flash
I am using the "load variables" script to send variables to a formmail.cgi program. It seems to work fine one minute then not work at all the next. Any ideas? Also, whats the best way to clear the fields so if the user returns to the section again the previous information is gone. Thanks
Flash Forms
Alright, I'm not sure if this is a newbie question or not but I figured since no question is a stupid question in the newbie section it would be a place to start. Well...
I wanna create a guest book type database where you can submit forms and then view them later kinda like saving them. I wanna know the easiest way to do this. Again I 'd like to know the EASIEST way.
Forms In Flash
i am trying to set up a form that the user fills out and then i recieve all the info in my eamil, i am using a cgi script.
mike
twicefound.com
Forms To Flash?
Ok I know that this is a common request but believe me I have look all over and cannot find what I need to know. I need to pass simple .html form values into flash. Wait that might be to simple. I have 4 different form fields(popups) that need to send their info to flash so that flash can use that info to build a file name and then use that file name to load the corrisponding .swf into the _root. level. I thought about the dump file with the info in a .txt file and the retrieve that. But my understanding is that if I do that then if I have multiple users that that could become a bottleneck and problems down the road. Any suggestion or point me in the direction of a tut on this would be great. Sorry to bother.
Thanks
Carter
Forms In Flash
What I want to do is I have a form that is working perfectly in html. But I want to re-create the same 'page' in a flash site. How do I go about doing this?
Forms In Flash
Is there any way to create a form in flash and submit the results to e-mail other than usign CGI?
i will appreciate your advice and help with this question.
Thank you
Forms And Flash Help
hi, i created a form using flash and used the url "http://us.geocities.yahoo.com/forms?login=kcluvsval" and sent using POST. When i fill out the form and click submit, it goes to the page and says "error while processing your input"
here is my script. Please help!!!! (btw, contact.swf is hosted on geocities.) the rest of the site is hosted on a doteasy.com server.
---------------------------------------------
on (release) {
subject = "Dreaming Emotion feedback";
recipient = "asian1@hotmail.com";
getURL ("http://us.geocities.yahoo.com/forms?login=kcluvsval", 0, "POST");
gotoAndPlay ("Thank You");
}
on (rollOver) {
tellTarget ("/submitmov") {
gotoAndPlay (2);
}
}
---------------------------------------------
also, here is a link to the swf.
http://www.geocities.com/kcluvsval/d...on/contact.swf
thanks alot!
Forms And Flash Help
hi, i created a form using flash and used the url "http://us.geocities.yahoo.com/forms?login=kcluvsval" and sent using POST. When i fill out the form and click submit, it goes to the page and says "error while processing your input"
here is my script. Please help!!!! (btw, the contact.swf file is hosted on geocities and the main site is hosted on a doteasy.net server)
---------------------------------------------
on (release) {
subject = "Dreaming Emotion feedback";
recipient = "asian1@hotmail.com";
getURL ("http://us.geocities.yahoo.com/forms?login=kcluvsval", 0, "POST");
gotoAndPlay ("Thank You");
}
on (rollOver) {
tellTarget ("/submitmov") {
gotoAndPlay (2);
}
}
---------------------------------------------
also, here is a link to the swf.
http://www.geocities.com/kcluvsval/d...on/contact.swf
thanks alot!
Flash 5 Forms...
my experience is comprised completely in design. i need to create a form for a client (a staffing company) that allows the user to enter a job description for my client. it will be a very simple form. should i pursue this through flash, or should i try and find an html solution? i have no experience in this stuff...
Flash MX Forms
Hi all. I have a question about making a form in flash mx. I have looked on macromedia's site and all i keep running into is a pizza form tut. I want to make a form with muliple input text fields. I have a sample action scripting from MX itself from the Form.fla and I have been changing it around but I am completly stuck. Can anyone help or point me to a tut other than how to make a pizza form?
I am having problems when it coms to showing me all the input I have put in from the previous page. I will show you the action scripting if it helps:
// push button callback
function onClick(btn)
{
trace("onClick " + btn._name);
if ( btn == pg1next ) {
// next button on page 1
getDataFromUIpg1();// get the data out of ui components on page 1
gotoAndStop("pg2");// go to pg 2
} else if ( btn == pg2prev ) {
// prev button on page 2
getDataFromUIpg2();// get the data out of ui components on page 2
gotoAndStop("pg1");// go to pg 1
} else if ( btn == pg2next ) {
// next button on page 2
getDataFromUIpg2();// get the data out of ui components on page 2
gotoAndStop("pg3");// go to pg 3
} else if ( btn == pg3prev ) {
// prev button on page 3
getDataFromUIpg3();// get the data out of ui components on page 3
gotoAndStop("pg2");// go to pg 2
}
}
// change handler for check box
function onChange(control)
{
if ( control == junkCheck_mc ) {
// enable and disable the list box based on check box value
interest_mc.setEnabled(junkCheck_mc.getValue());
}
}
// get the data from the ui elements on page 1
function getDataFromUIPg1()
{
loginData.nameField = name_txt.text;
loginData.emailField = email_txt.text;
loginData.teleField = telephone_text.text;
loginData.blank = genderGroup.getValue();
loginData.prefer = prefer.getValue();
loginData.overyear = overyear.getValue();
loginData.licenseddriver = licenseddriver.getValue();
loginData.leased = leased.getValue();
loginData.ifyes = ifyes.getValue();
}
// get the data from the ui elements on page 2
function getDataFromUIPg2()
{
loginData.junkMail = junkCheck_mc.getValue();
loginData.presentlease = presentlease.getValue();
loginData.whatmonth = whatmonth_text.text;
loginData.make = make_text.text;
loginData.model = model_text.text;
loginData.modelnum = modelnum_text.text;
loginData.month = month_text.text;
loginData.year = year_text.text;
loginData.wouldlease = wouldlease.getValue();
loginData.stateIndex = howdid_mc.getSelectedIndex();
loginData.interestIndex = interest_mc.getSelectedIndex();
}
// get the data from the ui elements on page 3
function getDataFromUIPg3()
{
// do nothing
}
// set the state of the ui elements on page 1 based
// upon the login data object
function updateUIFromDataPg1()
{
name_txt.text = loginData.nameField;
email_txt.text = loginData.emailField;}
{
howdid_mc.setSelectedIndex(loginData.stateIndex);
genderGroup.setValue(loginData.gender);
// set the state of the ui elements on page 2 based
// upon the login data object
function updateUIFromDataPg2()
{
for (var i=0; i<interestTable.length; i++) {
interest_mc.addItem(interestTable[i]);
}
interest_mc.setSelectedIndex(loginData.interestInd ex);
junkCheck_mc.setValue(loginData.junkMail);
onChange();
}
// set the state of the ui elements on page 3 based
// upon the login data object
function updateUIFromDataPg3()
{
// no ui but here for consistency
nameResult_txt.text = loginData.nameField;
doneResult_txt.text = loginData.emailField;
resultsGender_txt.text = loginData.gender;
resultsState_txt.text = stateTable[loginData.stateIndex];
resultsInterests_txt.text = interestTable[loginData.interestIndex];
}
function initData()
{
// make sure we only call initData once
if ( inited )
return;
inited = true;
// set up the state and interests arrays
// for fun - you can add more entries and the UI will reflect the changes
stateTable = new Array("CA", "NV", "BC");
interestTable = new Array("Golf", "Ski", "Flash Programming");
// modeling the form choices with data
// set initial values
loginData = new Object();
loginData.nameField ="";
loginData.questiontwo ="";
loginData.junkMail = true;
loginData.interestIndex = undefined;
}
__________________________________________________ _________
I am not seeing my email result field. I havent gone to the others yet. How can I see the result from the email field?
I have inputed dynamic text where I need to.
HELP!!
Gary
Flash Forms
hey peeps
im trying to develop a form with checkboxes that will send an e-mail when submitted. i have experience with this using html and cgi, but im curious how to do it using flash mx.
any help would be appreciated! thanks in advance.
CGI Forms From Flash
Hi Guys,
How does one setup regular CGI forms in Flash? More specifically, a simple form that sends the data to a specified email address. How easy is that? Or difficult. Help me out.
Thanks,
Marc
CGI Forms In Flash
Hi Guys,
How does one setup regular CGI forms in Flash? More specifically, a simple form that sends the data to a specified email address. How easy is that? Or difficult. Help me out.
Thanks,
Marc
Flash 5 Forms
Please help me. I am trying to get my head around form processing in flash and have set up a basic form with name, email, comments etc. These variables are contained elsewhere on the .swf file.
on (release) {
subject = "Feed Back Form";
recipient = "xxx@iprimus.com.au";
loadVariablesNum ("http://www.scripts.xxx.com/mailto.asp", 0, "POST");
gotoAndPlay ("ThankYou");
}
How do I get my server which uses asp to recognise and process the form. Forms drive me crazy! They are so easy with standard html. Why are they so hard in Flash?
Flash Forms
hey all,
I was wondering what *free* email services will except flash forms. I am currently using yahoo + lycos and having no luck.
thanx
* * * * Forms In Flash * * * *
OK, I'm using Flash mx, although I've been outputting my files as flash5. I'd say I'm an OK flash dude, but still learning... At any rate, what I'm wondering, is if there's a way to pull data from, like a text file, or an excel spreadsheet, or something and make it so that FLASH references your text file, and you don't have to update/edit the FLA... Kinda like PHP, Only not...heh
I'd also be curious if you could make it so that lets say, your swf file can sense NEW text files in the same directory, and update it's database automatically, y'know like if you had an ACCESS database, and you added a new table...
Anyways, these questions are kind of involved, but hey, even if someone could just point me in the right direction, that would be great. -Thanks in advance!
Forms In Flash?
Is there a way i can have something like an "Enter comments here" and then a "view comments" in flash? So that a comment, when entered, would display name and comment in a certain movieclip?
Im making a livejournal template, and many people have asked for that ability, yet I have no clue how to implement it. Any thoughts?
~DW~
Forms & Flash MX
Hi! This is my first posting. I am creating a form in Flash MX, but it's not working. The form is a movie clip I bring into the main scene.
On the 'SEND' button the action script is:
on (release) {
subject = "Estimate request";
recipient = "forms@webalacarte.ca";
recipient= "karima@webalacarte.ca";
loadVariables("/cgi-sys/formmail.pl","1",'POST');
gotoAndPlay("thanks");
sort = "first,last,mail,tel,list1,list2,cbgraphics,cbpass word,cblogo,cbphotos,cbanimation,cbguest,comment"
}
The CGI address was supplied by my Host. The only other action script is on a seperate layer in the MC and deals with global style format for the UI components. Any suggestions?
You can check the site at http://www.webalacarte.ca
Help With Forms And Flash MX
I am in the middle switching to flash MX for all my forms on my website and need a little help. I am sending URL encoded variables through the loadVariables method to my business logic witch is a bunch of Java Beans. Currently I use input and output wait loops to wait for the response back from the beans. Now for my question... With Flash MX is there an easier cleaner way to get data back and forth without using XML and input/output wait loops??
-bbarre
Flash Forms?
i have HTML forms that use java servlets...i want to change these forms into Flash forms (using MX)...can i simpliy re-use the existing servlets?
what is required for me to do on the Flash side? i'm a newbie, this is all i have so far:
formData = new LoadVars();
formData.name_txt = "";
formData.ext_txt = "";
formData.dept.cb = "";
I do not have the coldfusion server, i dn't think it's needed for this (no database interaction)
Forms In Flash 5
Hello.. I am developing a flash 5 navigation system for a site i am working on. built into the navigation is a login area for the web mail system. i have the text input fields named correctly and i have the hidden variables in place in a blank frame. the only thing i do not know how to add is the name of the form. in the HTML version, the form tag has the form name listed. it's a cgi form, and i am not sure if the form name is a necessary parameter.
any help is appreciated, and please let me know if you need more info.
Flash Forms
How do i make a flash form and have it submit to an email or database? thanks
|