IE:
<Param name = "movie" value00000000test.swf "/>
<Param name = "quality" value = "high"/>
<Param name = "flashvars" value = "STR = flashpixy"/>
<Param name = "menu" value = "false"/>
<Embed
Src00000000test.swf"
Quality = "high"
Pluginspage = "http://www.macromedia.com/go/getflashplayer"
Type = "application/X-Shockwave-Flash"
Width = "550 ″
Height = "400"/>
Firfox:
<Param name = "movie" value00000000test.swf "/>
<Param name = "quality" value = "high"/>
<Param name = "flashvars" value = "youurl = 123"/>
<Param name = "menu" value = "false"/>
<Embed
Flashvars = "STR = flashpixy"
Src00000000test.swf"
Quality = "high"
Pluginspage = "http://www.macromedia.com/go/getflashplayer"
Type = "application/X-Shockwave-Flash"
Width = "550 ″
Height = "400"/>
Note that the locations added to these two browsers are different. But for insurance, it is best to add them, and it is not in the way. Because of the ieupgrade, if Flash is released (Press F12) in a previous version, there will be a virtual box around flash. Only after clicking it can flash get the focus, however, the current flash release directly solves this problem and generates an ac_runactivecontent.js file. Therefore, to pass parameters through flashvars, remember to modify it here:
If (ac_fl_runcontent = 0 ){
Alert ("this page requires ac_runactivecontent.js .");
} Else {
Ac_fl_runcontent (
'Codebase', 'HTTP: // download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab?version=9,0, 0, 0 ′,
'Width', '123 ′,
'Height', '000000 ′,
'Src', 'test ',
'Quality', 'high ',
'Pluginspage', 'HTTP: // www.macromedia.com/go/getflashplayer ',
'Alipay', 'middle ',
'Play', 'true ',
'Login', 'true ',
'Scale', 'showall ',
'Wmode', 'window ',
'Devicefont ', 'false ',
'Id', 'test ',
'Bgcolor', '# ffff ',
'Name', 'test ',
'Menu ', 'false ',
'Allowfullscreen ', 'false ',
'AllowScriptAccess', 'sample ',
'Movie ', 'test ',
'Flashvars', 'str = flashpixy ',
'Salign ',"
); // End AC code
}
//
In as3, flash uses root. loaderinfo. Parameters // or stage. loaderinfo. parameters to obtain the passed parameters.
In Flex 2, the passed parameters are obtained through: application. application. parameters.