0

Since using iframes to house external pages are, by some accounts "not the preferred method" and even disallowed by some sites (flickr, for one), I now want to dynamically generate browser tabs. e.g., when a user submits a form, I want to dynamically generate a tab on the browser in response to what is submitted. e.g., I might want to add a new tab with an URL like: http://www.bigsurgarrapata.com/contact

How to do this in jQuery?

4

2 回答 2

2

我相信您可以在提交时打开一个新标签,只需添加

target="_blank" 

到提交按钮的html。

于 2013-05-14T16:14:38.977 回答
1

您想要target带有属性的表单action属性。

http://www.w3schools.com/tags/att_form_target.asp

浏览器对目标属性的结果具有最终控制权,但大多数浏览器会打开一个值为 _blank 的新选项卡。

<form action="contact_submit.php" target="_blank" method="POST">
于 2013-05-14T16:17:34.273 回答