VaR Str = Loaderinfo. Parameters [ " True_name " ];
Note: The parameter name is. SWF ?... Address
In fact, it is very simple. I used to use: xx.swf? Xx = 11 & xxx = 22 ...... It is inconvenient to pass parameters to flash. Later I checked the param tag. Oh, it's too easy ~ I would like to share with you the following!
In the webpage, add a sentence under the <OBJECT tagCode: <Param name = "flashvars" value = "xx = 1 & xxx = 2"/>
In flash, the value can be directly used: XX or XXX!
Of course, the above method is for As2, so what should as3 do? Of course, parameters is used!
Use in Flash: stage (stage can be left blank, this is available). loaderinfo. Parameters. XX (XX is the parameter name imported from the web page described above) or take it like this:Stage. loaderinfo. Parameters [0];
Haha, I 've done it before. I forgot. Today I met someone else's as2 code and reviewed it. By the way, I recorded it for my reference ~ If it is helpful to you, please leave a footprint, 3q ~