Solved

Flash 8 session to php

Posted on 2006-11-02
1
209 Views
Last Modified: 2012-05-05
URGENT
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
0
Comment
Question by:Robinsonx6
1 Comment
 
LVL 11

Accepted Solution

by:
ch2 earned 500 total points
ID: 17857333
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:

getURL('yourfile.php','_SELF','GET');

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

in your php write something like this;

$session['lang'] = isset($_GET['lang']) ? $_GET['lang'] : $session['lang'];
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This is a very simple example to help those of you who are still migrating from AS2 to AS3 understand the redesigned event model in AS3. In AS2.0, event functions (that is, the function to be performed when an event is fired) were stored as a pro…
This article describes a solution to a problem of subloading one movie into another when they have different SWF versions. Sometime back, I was working on an ActionScript project while I came across an interesting fact which I would like to share…
In this tutorial viewers will learn how to create a basic shape tween animation in Flash including shape hints for smooth animation Open a new document in Flash: Draw a shape: Select another frame (how long you want the tween to be): Right click and…
The goal of the tutorial is to teach the user how to select which audio input to use. Once you have an audio input plugged into the laptop or computer, you will go into the audio input settings and choose which audio input you want to use.

823 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question