Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/asp.net/30.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 在新选项卡中打开链接_Javascript_Asp.net_Window.open - Fatal编程技术网

Javascript 在新选项卡中打开链接

Javascript 在新选项卡中打开链接,javascript,asp.net,window.open,Javascript,Asp.net,Window.open,我使用imagebutton将项目ID作为命令参数发送。在窗口中,我只显示一张图片,那就是imagebutton。单击该图像时,我希望在新选项卡中打开相关项目的所有图片 这个代码在代码背后 int ID = Convert.ToInt32(e.CommandArgument); ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "", string.Format("yenipencere = window.open('Pr

我使用imagebutton将项目ID作为命令参数发送。在窗口中,我只显示一张图片,那就是imagebutton。单击该图像时,我希望在新选项卡中打开相关项目的所有图片

这个代码在代码背后

int ID = Convert.ToInt32(e.CommandArgument);
ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "", string.Format("yenipencere = window.open('Projeresim.aspx?ProjeID={0}','_blank')", ID), true);
我可以在Firefox和Internet Explorer中很好地管理它,但Chrome坚持以弹出窗口的形式打开它。我有没有办法在Chrome中实现这一点,或者这是Chrome的默认设置


我知道我可以使用其他链接方法,但我需要发送一个ID作为参数。

你不能,这是浏览器设置。这可能是我可以的复制。即使在chrome中,我也可以使用a href target=“\u blank”来实现这一点。问题是我需要发送一个参数,是的,这是一个类似的问题,你的链接马库斯,但他们没有我需要的答案。可能重复的