Flasher Archive

[Previous] [Next] - [Index] [Thread Index] - [Previous in Thread] [Next in Thread]


Subject: FLASH: Pause Actions?
From: Dino Giacomazzi
Date: Mon, 20 Dec 1999 17:12:26 GMT

Hey Flashers,

Im working on a signup form so people can submit their email address for a
mailing list. I got together with my neighborhood perl programmer and he
modified his standard mail.cgi to send a variable value back to flash based
on a couple of things...they are

1. if the email address is not valid (no @) then send scriptStatus = 0
2. if the email address is already in the database send scriptStatus = 2
3. if the email address is ok and not in the database send scriptStatus = 1

In my movie i have a hidden text variable called scriptStatus which displays
the value from the CGI. This all works perfectly and I love it very much.
I then put an if statement in the button that looks like this:

On (Release, Key: <Enter>)
Load Variables ("http://www.bigrockstar.com/signup/mailer-flash.cgi",
0, vars=POST)
If ((scriptStatus) = 1)
Go to and Stop ("ok")
Else If ((scriptStatus) = 0)
Go to and Stop ("address")
Else If ((scriptStatus) = 2)
Go to and Stop ("already")
End If
End On

Every time I submit an address it goes to the named frame "address"
(scriptStatus =0 i.e. invalid email address).
In the scriptStatus text variable box, it displays the proper number 0, 1,
or 2..

I have also noticed there is a deley from the time you click the submit
button until the number shows up in the scriptStatus box. So my guess is
that the if statement in the button is reading the scriptStatus box before
the data comes back from the server, therefore, its blank and gets a value
of 0, or no value at all and is going to scriptStatus= 0..


Now my Question! How can i pause the actions script so that there is time
for the CGI to post back to flash before the If statement reads the
variable?

Any other solutions to this puzzle would be greatly appreciated as well.

Dino

PS. this is the first time I have tried to use IF/ELSE and really have no
idea how it works so my script could be completely screwed as well...

thanks in advance

dg









flasher is generously supported by...
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Streaming Media WEST '99 Conference & Exhibition
"The Worlds largest Internet Audio & Video Event"
December 7 - 9, San Jose Convention Center, California

Reserve your space today at http://www.streamingmedia.com
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To unsubscribe or change your list settings go to
http://www.chinwag.com/flasher or email helpatchinwag [dot] com


Replies
  Re: FLASH: Pause Actions?, Samuel Morello
  Re: FLASH: Pause Actions?, Samuel Morello

[Previous] [Next] - [Index] [Thread Index] - [Next in Thread] [Previous in Thread]