0
在GWTP,在新标签中打开网页,我们可以利用这一点:(GWTP)“placeManager.revealPlace(request)”可以在新的Tab中打开一个URL吗?
PlaceRequest request =new PlaceRequest(NameTokens.getorder).with("myID", myID);
String url =
Window.Location.createUrlBuilder().setHash(placeManager.buildHistoryToken(request)).buildString();
Window.open(url, "_blank", null);
我们能否不使用Window.open
&只是用placeManager
才达到同样的事情(即在打开一个URL新标签)。
PlaceRequest request =new PlaceRequest(NameTokens.getorder).with("myID", myID);
placeManager.revealPlace(request);
// this code will open the url (ex: mydomain.com#getorder;myID=15) in the current browser.
的Window.open(url, "_blank", null);
的问题是,有时它会打开新的标签&有时它会打开一个新的窗口,它是不一致的。
感谢,它的工作好了,现在 – Tum
欢迎,好消息:) – Braj