#1
  1. No Profile Picture
    Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2001
    Posts
    29
    Rep Power
    0

    PHP - Flash interaction


    Hello!

    I've got a problem: I can't get some variables loaded into my flash movie. It is meant for a login script. The actionscript, which posts the key:

    on (release) {
    loadVariablesNum("http://localhost/onderzoek-online/site2/dev/Login.php", 0, "GET");
    if (access == 1)
    {getURL("http://www.onderzoek-online.nl", "_blank", "GET");}
    else
    {gotoAndStop(15);}
    }

    The PHP (test) script:

    <?PHP
    if($HTTP_GET_VARS["key"] == "correct-login")
    {
    echo "access=1";
    }
    else
    {
    echo "access=0";
    }
    ?>

    Thanks for helping me.
  2. #2
  3. busy...is there any other way?
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2001
    Location
    Amersfoort, Netherlands
    Posts
    259
    Rep Power
    13
    To make flash 'see' variables you have to make it like:

    &access=1

    so you can test the connection between flash and php with

    PHP Code:
    <?
    echo "&access=1";
    ?>
    and nothing more, when you get flash working with this, then create the correct function in the phpfile to set the access variable

    g'luck

IMN logo majestic logo threadwatch logo seochat tools logo