-
[F8] Check Box Variable Assignment
Hello,
I have got a component within my flash form. I have a button that sends information to PHP (this is working, no help needed for this bit).
What I need help with is checking whether the check box is selected or not, so that if it is my button will go to one place, and if not then it will go to another (which I know will be done with an 'if' statement).
Any help would be great.
Cheers,
-
I don't use components, but basically
PHP Code:
var bCheckboxClicked = false;
if (bCheckboxClicked){
//do this
}else{
//do this
}
when the check box is clicked you would set the variable to true, the If checks to see if the variable is true, if it is. Do want you want, if it is not, do the other.
IMS
-
I cannot get this working.
Basically by tick/check box has the following names:
label:- 'CheckBox'
Instance Name:- 'CheckBoxInstance'
My button does the following:
on (release) {
form.loadVariables("email.php", "POST");
form2.loadVariables("email.php", "POST");
gotoAndStop(3);
}
I need it so that on release, if the box is ticked it does the above, if not it will go back to (1).
Cheers
p.s. Sorry about not putting the code in the table like you, I do not know how too.
-
the button should look like this:
PHP Code:
on (release) {
if (box1Cecked == true){
form.loadVariables("email.php", "POST");
form2.loadVariables("email.php", "POST");
gotoAndStop(3);
}else{
gotoAndStop(1);
}
}
something along those lines
IMS
-
Thanks,
But what is it I name 'box1Cecked' and where do I declare this? On the checkbox?
How does this change to true when the user selects the box?
Cheers,
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
|