actually this feature is broken.

if you try to add a param that is unrecognized by embedFlash, it will
not add it as a parameter tag.

we found there are 2 better ways to load the swf file right now.

option1.

use swfObject1-5 it has a superior interface and is more fault
tolerant when it comes to browsers, the downside is that getting 100%
width and 100% height properties is tough with swfObject1-5.  if you
want to cache the flash file(its slow right now) you will want to do a
getProxyUrl on your swf location url first, and then send that string
to swfObject1-5.

var url = "http://yourdomain.com/file.swf";;
     url = gadget.io.getProxyUrl(url);

option2.

use the broken embedFlash function, but encode flashvars in the url.
if the settings change, then it will re-cahce the swft object.
DO NOT DO THIS WITH PRIVATE DATA!!!
but in the case of a userid, you are probably fine.

var url          = "http://yourdomain.com/file.swf";;
var flashvars = "var1=value1&var2=value2";

     url          = url + "?" + flashvars ;   //adds flash vars to
your url

option 1 + 2


var url          = "http://yourdomain.com/file.swf";;
var flashvars = "var1=value1&var2=value2";

     url          = url + "?" + flashvars ;

     url          = gadget.io.getProxyUrl(url); //proxy encode your url
+flashvars


right now there are a few options that are only available through
swfObject like

allowFullScreen               //allows the flash widget to go full
screen, esc always exits fullscreen, and keyboard becomes disabled as
input into flash
allowScriptAccess           //defines the javascript flash bridge
allowNetworking               //defines local connection access

embedFlash will not let you set these params either by design or by
flaw, either way its not there.  I think it should be there because of
adobe's overly restrictive security models, that are far more strict/
annoying than javascript.


On Mar 3, 7:10 am, rush <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> I want to pass username to swf file. It was working fine when i use
> _IG_EmbedCachedFlash, but pass blank when use
> gadgets.flash.embedFlash. I am using following code, is it ok or have
> some mistake.
>
> gadgets.flash.embedFlash(url, "flashComponent", {
>                                         swf_version: 8,width:800,
>                                         height: 600,
>                                         id: "flashid",
>                                         flashvars: 'username='+ _esc(username)
>
>                                         })
>
> Thanks
> Rush
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"OpenSocial Application Development" group.
To post to this group, send email to opensocial-api@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/opensocial-api?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to