IFRAME 使 src servlet 在 ipad safari 上执行两次
我有一个 iframe
,它从 servlet
获取其内容。问题在于,加载 iframe
页面时,servlet
doGet 方法执行了两次。这是 html:
<div style="position: absolute;top: 135px;left:0px;overflow-y:scroll;overflow-x:scroll;width: 975px;height: 873px;" align="center">
<iframe src="documentviewer?docid=#{viewIncomingBean.connectedAttachment.id}" width="630px" height="873px" style="border: 1px solid black;"></iframe>
</div>
只有当我在 ipad safari 上运行应用程序时才会出现此问题,在 firefox 上运行良好
有什么方法可以防止 servlet 的双重执行?
I have an iframe
which gets its content from a servlet
. The problem is that the servlet
doGet method gets executed twice when the page of the iframe
is loaded. Here is the html:
<div style="position: absolute;top: 135px;left:0px;overflow-y:scroll;overflow-x:scroll;width: 975px;height: 873px;" align="center">
<iframe src="documentviewer?docid=#{viewIncomingBean.connectedAttachment.id}" width="630px" height="873px" style="border: 1px solid black;"></iframe>
</div>
this problem only show up when i run the application on ipad
safari, it works fine on firefox
Is there any way to prevent the double execution of the servlet
?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
是否存在合法两次调用 doGet 方法的问题?这里有2个页面请求,1个针对页面,1个针对IFRAME。
如果我误解了问题所在,请告诉我。
Is there a problem that it is hitting your doGet method twice legitimately? There are 2 page requests here, 1 for the page and 1 for the IFRAME.
If I am misunderstanding what is wrong, let me know.