开发者

How to Insert an external jsp in GWT whithout using iframe

开发者 https://www.devze.com 2023-02-06 05:59 出处:网络
i want to insert an ext开发者_运维百科ernal jsp in our gwt app. With the frame widget from GWT that is possible, but this is not exactly, what i\'m looking for. The problem is, that with iframe i have

i want to insert an ext开发者_运维百科ernal jsp in our gwt app. With the frame widget from GWT that is possible, but this is not exactly, what i'm looking for. The problem is, that with iframe i have more than one DOM...but i wish to have exactly one DOM. Any suggestion, how to solve the problem?


You could fetch the inner page's HTML (using RequestBuilder) and call setInnerHTML() on some element in your DOM.

This is pretty risky, and you'll need to really fully vet the HTML that you're setting in there, but it is possible.


You can use JSTL <c:import> to import external resources. You only need to take care that the final HTML is valid and you thus don't end up with nested <html> tags or so.

0

精彩评论

暂无评论...
验证码 换一张
取 消