-
[RESOLVED] Please help with Flashvars + Cookie problem
Hi, I am trying to get a value from a cookie and pass it to my SWF but I cant seem to get it :-/
The cookie's data is very simple. No special characters or symbols, just numbers. The numbers correlate to an image that is clicked on so that when someone clicks on a given thumbnail a flash based gallery will load to that picture first.
I just need some help figuring out how to pass the value in the cookie, unfortunately it's not as easy as the tutorials make it seem.
Below is some of the codes I have tried.
Could someone please point out the mistake?
This works but it is hardcoded so that wont work
Code:
<param name="FlashVars" value="myvar1=3">
this doesn't work
Code:
<param name="FlashVars" value="myvar1="+<script>document.write(GetCookie('KKITEST'));</script>+"">
and this also doesn't work.
Code:
<PARAM NAME=FlashVars VALUE="myvar1=' + getCookie('KKITEST')+'">
How can this be fixed?
~KK
-
Update
These don't work either, the first one is the just the coding as a string and the second does nothing.
Code:
<param name="FlashVars" value="myvar1=javascript:document.write(GetCookie('KKITEST'))">
Code:
<param name="FlashVars" value="myvar1="+javascript:document.write(GetCookie('KKITEST'))+"">
I will keep at it, but help would be nice
~KK
-
Here is what I decided on, if you want to use the code all you have to do is set $MyVar to whatever value you want.
PHP Code:
<?php
$MyVar = 25;
print("<param name=\"FlashVars\" value=\"myvar1=$MyVar\">\n");
?>
~KK
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|