Can you put up your movie file??? I think that will be faster…
ok
i uploaded it
http://members.rogers.com/lastdon00/helpagain.fla
it’s not zipped though
i hope that doesn’t matter
Yup… As long as it is less than 1 meg, it’s fine… I am on 56k…
I’ll take a look at it when the transfer is done… I am not quite sure if I understand your question though… Let’s see…
Um… What am I looking for here???
what u r looking for is Submit button
i have a layer called actions.
and i started some scripting in there.
what to send on submit
but i dunno how to populate the radio buttons and
check boxes, to the email form
that is what id ont get… because when i do it…
just like u did in mug’s file, i can radiobutton:(Object)
no selected value
Try this…
Send.onRelease = function()
{
if (store.text != "")
{
myLVs = new LoadVars();
myLVs.store = store.text;
myLVs.radioGroupp = radioGroupp.getValue();
myLVs.restaurant1 = restaurant1.getValue();
myLVs.restaurant2 = restaurant2.getValue();
myLVs.restaurant3 = restaurant3.getValue();
myLVs.restaurant4 = restaurant4.getValue();
myLVs.restaurant5 = restaurant5.getValue();
myLVs.other = other.text;
myLVs.radioGroup = radioGroup.getValue();
myLVs.radioGroup1 = radioGroup1.getValue();
myLVs.radioGroup2 = radioGroup2.getValue();
myLVs.details = details.text;
myLVs.traffic = traffic.text;
myLVs.radioGroup3 = radioGroup3.getValue();
myLVs.sponsor = sponsor.text;
myLVs.annual = annual.text;
myLVs.radioGroup4 = radioGroup4.getValue();
myLVs.raising = raising.text;
myLVs.comments = comments.text;
myLVs.sendThis = null;
myLVs.send("http://www.etech-logic.com/cgi-bin/FormMailsecure.pl", myLVs, "POST");
}
else
{
trace("Store number is missing...");
}
};
You will have to make sure that the variable name and such should be set to the same in this script and the one from the retrieve button…
Let me know if you need further assistance…
ok it worked
question
istead of saying true for the checkbox
is there is a way to get
the name like McCafe
or Drive Thru?
all it says is true
and if i dont check a check mark it returns false
is there a way so it will ony send data to the script if something is selected in the check box field cause my asp page wont like that
so i need only if McCafe or drive thru etc are check that the data is passed
can u see i suck at flash?
lol
That is where you gotta look up the lists of functions for the FCheckBox from the ActionScript Dictionary…
Send.onRelease = function()
{
if (store.text != "")
{
myLVs = new LoadVars();
myLVs.store = store.text;
myLVs.radioGroupp = radioGroupp.getValue();
myLVs.restaurant1 = restaurant1.getValue() ? restaurant1.getLabel():false;
myLVs.restaurant2 = restaurant2.getValue() ? restaurant1.getLabel():false;
myLVs.restaurant3 = restaurant3.getValue() ? restaurant1.getLabel():false;
myLVs.restaurant4 = restaurant4.getValue() ? restaurant1.getLabel():false;
myLVs.restaurant5 = restaurant5.getValue() ? restaurant1.getLabel():false;
myLVs.other = other.text;
myLVs.radioGroup = radioGroup.getValue();
myLVs.radioGroup1 = radioGroup1.getValue();
myLVs.radioGroup2 = radioGroup2.getValue();
myLVs.details = details.text;
myLVs.traffic = traffic.text;
myLVs.radioGroup3 = radioGroup3.getValue();
myLVs.sponsor = sponsor.text;
myLVs.annual = annual.text;
myLVs.radioGroup4 = radioGroup4.getValue();
myLVs.raising = raising.text;
myLVs.comments = comments.text;
myLVs.sendThis = null;
myLVs.send("http://www.etech-logic.com/cgi-bin/FormMailsecure.pl", myLVs, "POST");
}
else
{
trace("Store number is missing...");
}
};
If selected, it will display the label on that check box, and if not selected, it will simplay say false…
:’(
what am i suposed to looking for ?
???
:whistle: a lil hint!!
when i go through my CGI script for some reason it still
says
restaurant2: false
i hate this crap lol
maybe i can do an if statment?
or something?
so IF selected only to pass the variables?
For example…
myLVs.restaurant1 = restaurant1.getValue() ? restaurant1.getLabel():false;
What this line means is store ‘restaurant1.getLabel()’ into this variable, myLVs.restaurant1, only if this condition, ‘restaurant1.getValue()’, is met, otherwise set that variable to ‘false’…
what happens though if it’s not selected, the value for
restaurant2 and 3 4 5 still pass a variable of restaurant2: flase
how can i stop it from passing that variable?..
cause if i selected restaurant1 it passes McCafe which is right,
but if u have no check marks in the others nothing should pass
i dunno how to control that, i was thining an IF?
if this blahb lah
So, you don’t want to send nothing if the check box is not selected??? Yes… Put up all the if statements in that case… You should have at least five if statements for that at least… But I’d just stick with what I have… What wrong with additional variable that says false??? You can just ignore it later on…
Yeh i dont want to send any variable if it’s not selected
how can i embed the IF statement in it i am trying but it’s not working
i can’t have the extra stuff go through cause in asp i have a line that calls restaurant2 so if nothng is selected it writes False to the database,
i tried this
[AS]
myLVs.restaurant2 = restaurant2.getValue() ? restaurant2.getLabel():24+Hrs;
myLVs.restaurant3 = restaurant3.getValue() ? restaurant3.getLabel():Drive+Thru; [/AS]
but again if nothing is selected a ZERO or a NAN goes through lol
so can u show me a lil how to do the IF statment pretty pretty please !!
Um… If I were you, I’d just take care of it at the back end… Well…
if (restaurant2.getValue())
{
myLVs.restaurant2 = restaurant2.getLabel();
}
should do it… Apply this to all other occasions…
else
{
trace(“Store number is missing…”);
}
what does this do if u dont mind my asking?
…
lemme ask since ur online before we all go to sleep
if i do this for the store number validation i guess.
if (store=Null)
gotoSTop( a movie layer and tell them to put a new number)
someting like that woud it work?
Um… Are you saying you don’t know what that trace() function does??? Man, you gotta read ‘Using Flash’ and "ActionScript Dictionary’ first…
What that does is to print out the string onto the screen while authoring the movie…
That if statement is not valid…
if (store.text == null) { blah blah }
should work…
what Do u think is the best way for a person to see the error message
If they have put the Store Number in for them to see a message?
and the last question.
to validate the form… example,
U enter in the Store number but it does not exist in the database.
would i have to make the scipt in the Flash File or in the Server side? to return a window that says Please enter in correct store number?
so
example
If ur store 7855
but U type in store 7854 u get an error message saying
Store does not exist.
Um… I’d do this…
Send button sends the store number and ASP script checks the database to see if that number exists or not, and have it send the result back to Flash… And when the result is back, you can show the message box that says either ‘success’ or ‘store number not valid’…
For the message box… You can either use Flash UI Component set II’s message box or create your own… And hide/unhide depending on the result back from the ASP script…
Did I answer you right???
ok so this is for the validation right?..
so if the store number is wrong it should go through the ASP page right?
i can make probably a dynamic text box i dunno how to hide unhide things,
flash componets 2? are avaiable at macromedia right?
i haven’t done any updates yet.
hey
i got a question lol
i ws just reading up on this. on javascript lol i know u like me asking u question lol
if (store.text == null) { blah blah }
can i put a {javascript pop up window in here instead of putting in flash? saying Please enter in A store number?