我正在研究一个工程,在战争中我运行了套装的服务器,在战争中倾听请求,并在单独的页面上播放外国迪维。初始请求是向服务器 (a) 提出,如果需要显示数据,则会生成 HTML 。如果没有数据,它会将查询字符串传送到另一个服务器,以便处理请求,然后提供一个有选项选择的页面。
我正在用Windows Server 2008 运行 Tomcat 6。
但我遇到了两个问题:
- When I use redirect, I get no response from the servlet being
redirected to. I have some javascript alerts up that are never called by the (b)
servlet. I AM using relative paths and confirm the link is correct in logs. - When I copy that link in step 1 in a new window, I see the results. Just not when it s embedded in another page that makes the request. Why would that be? Is it possibly a limitation from the host page and not being able to render the response?
- When I use a forward, I see the servlet response, but then a new window opens. Thus taking the person away from the original page. This would be great if the results render in the same page.
有什么最佳做法可以保证我能够使用第一个服务器的响应对象,从最初的服务器调用到另一个服务器的“转机”呢?