Flash 8 session to php

within my flash object i have buttons to change the language which is used for the site

how do i get my button to alter the php's current session variable $session['lang'];

Thanks in advance
Who is Participating?
ch2Connect With a Mentor Commented:
To pass the session to flash 8, i'd use FlashVars:

            <param name="FlashVars" value="lang=$session['lang']">
            <embed FlashVars="lang=$session['lang']"</embed>

From here in Flash 8 you have set the variable _root.lang

To pass it to php use the next script in your button:


From here in php you have $_GET['lang']

in your php write something like this;

$session['lang'] = isset($_GET['lang']) ? $_GET['lang'] : $session['lang'];
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.