open url in one window with javascript action

Hi Guys, I tried to open a URL in one window with a javascript action as below.  I was expecting it will only open one window when I click multiple times one the button to trigger the javascript code, but it will always open a new window when I click on the button. any idea how to prevent it open multiple new windows for me?     when i click on this button for three times, it will open three windows for me, thats not what i expected:
2 answers

You are specifically targetting _blank when opening your window, and this is a special case that will always open in a new window or tab.

You need to change this to a unique name so if you open the URL again, if it has the same unique name as the previous window it will open in that and not a new window.

For more information on the target names and special cases, please take a look at the following page.

I hope this helps.


Hi Ryan Ge,

You had given as blank so it will open in 3 different tabs. Do u want to  open in same window?