# Add second parameter to Flashvar

**URL:** <https://forum.kirupa.com/t/add-second-parameter-to-flashvar/287648>\
**Category:** flash\
**Created:** [May 4, 2009, 6:25pm UTC](https://forum.kirupa.com/t/add-second-parameter-to-flashvar/287648 "2009-05-04T18:25:16Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![addison1111](https://avatars.discourse-cdn.com/v4/letter/a/cc9497/32.png) [@addison1111](https://forum.kirupa.com/u/addison1111)\
**Post date:** [May 4, 2009, 6:25pm UTC](https://forum.kirupa.com/t/add-second-parameter-to-flashvar/287648/1 "2009-05-04T18:25:16Z")

</div>

Hi all,

I’m new so please forgive my ignorance!

I was asked the following:

> We need a second parameter added  
> that sets the destination/target for the link. The default/current  
> is \_blank but we also need to be able to set this to nothing so it opens in  
> the same window.

Can you try adding the second parameter to the flashvars list and use this  
to set the target for the link.  
my html is:

> 

```
&lt;object width="296" height="88"&gt;
    &lt;param name="movie" value="../soccer_homepage_AM2.swf" /&gt;
    &lt;param name="FlashVars" value="url=/mainpage_gif.html" /&gt;
    &lt;embed src="images/Main_Page Banners/Soccer/soccer_homepage_AM2.swf" FlashVars="url=/mainpage_gif.html" width="296" 

```

height=“88”\>\</embed\>  
\</object\>

How to I add that second parameter of opening in same window to the flashvar?

I believe you separate the additional one by using a & but am unsure exactly what to put?

Do I also have to change the ActionScript in the original fla file? This is set to \_blank but I believe they want it to stay that way but have the option of adding \_self or whatever it needs to be in the Flashvar when needed.

My ActionScript 3.0 is:

> btnLink.addEventListener(MouseEvent.CLICK, buttonSymbol\_click);

function buttonSymbol\_click(evt:MouseEvent):void {  
var req:URLRequest = new URLRequest(stage.loaderInfo.parameters[“url”]);  
navigateToURL(req, “\_blank”);  
}
