PDA

View Full Version : Help needed, "password" doesnt work (FLASH MX)



Atticus11182
May 12th, 2004, 10:20 PM
i have a box similar to a credit card scanning box. to enter the site, it requires the user to enter "566404663" (that is "long_gone" on the numerical/alphabetical keypad) then click the enter key. when the user clicks on the enter key, it takes him to the site.

PROBLEM: when the user clicks enter, reguardless of what the user entered, it takes him to the site. i want it to only go to the site if the user enters "566404663" and clicks enter.

this is my actionscript for the button:
on (release) {
if (display = "566404663") {
getURL("http://www.geocities.com/taikobou_20/index.htm", "_blank");
} else {
displayStatus ="0";
}
}


can you please help me re-write this actionscript so that when the user clicks "566404663" and clicks on enter that it takes the user to the site and if the user enters anything other than "566404663" and clicks on enter that it would reset the display to 0?

check out the link to see the credit card scanning box:
http://www.geocities.com/taikobou_20/creditbox.swf

thanks so much for your time.
Alex

Adam
May 12th, 2004, 10:29 PM
try:

on (release) {
if (display == "566404663") {
getURL("http://www.geocities.com/taikobou_20/index.htm", "_blank");
} else {
displayStatus ="0";
}
}

the double == checks for equality....

also, if display is a text box, caoulnd't you just use:

if (display == "long_gone") ??

p.s. I keep trying to convince my g/f that when we have a kid that we need to name him Atticus...she's a tough sell, but I think I'll get her..LOVE that name ;)

Adam

Atticus11182
May 13th, 2004, 12:34 AM
thanks for your help, ill work with it, i tried that earlier i think but if i remember right i didnt get it to work, it was a complete mess if you know what i mean, good thing its just for fun

i love the name atticus too lol... that would be a cool name for a kid

Adam
May 13th, 2004, 12:36 AM
cool, anymore issues with it, just post 'em, and if I'm not around I'm sure someone else will help you ;)

p.s..can I give you my g/f's email so you can tell her how cool Atticus would be for a kid? lol

Adam

Atticus11182
May 13th, 2004, 12:42 AM
sure no problem lol...

ill keep workin with it, its pretty cool to have the support of everyone...

Adam
May 13th, 2004, 12:44 AM
It appears you're new here, so firstly, welcome to Kirupa!!!...this place is VERY helpful...so many smart smart people here....and friendly and helpful too...this website is a real gem :)