请问tomcat如何实现访问http://****,跳转到http://****/web/my.jsp. 请问tomcat如何实现访问http://****,跳转到http://****/web/my.jsp. 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 可以使用forward、redirect……或者一个form表单提交不知道Lzy的展示页面时用什么写的 也可以通过filter或拦截器来实现 web.xml<!-- 欢迎界面--> <welcome-file-list> <welcome-file>index.jsp</welcome-file> </welcome-file-list> web.xml<!-- 欢迎界面--><welcome-file-list><welcome-file>/web/my.jsp.</welcome-file></welcome-file-list> 也可以在Tomcat的配置文件中设置 转发:request.getRequestDispatcher("输入你要转发的网址名").forward(request, response);重定向:response.sendRedirect("输入你要转发的网址名") 在tomcat目录的root下的index.html的内容改为<script language="javascript" type="text/javascript"> setTimeout("javascript:location.href='http://***'", 0); </script> 在http://**** 页面中加上个跳转代码<%response.sendRedirect(request.getContextPath() + "/web/my.jsp");%> 总结以上各位答案:1:请求转发2:重定向3:javascript 请问哪个用过NTKO_OFFICE文档控件啊! 连接数据库 属性设置中为什么带上queryResult=new StringBuffer() TOMCAT启动慢 关于servlet中几个方法 请问各位高手我的TOMCAT环境变量设置是哪里出错了 各位!数据源的问题!我实在没办法了,求救各位啊!~~~~~~~~~~~~~~~~~~ IT领域的P2P技术 很着急!一个关于application的应用! 文件成功上传后,成功下载,但是不能用了!!!!!!!! sessin刷新的问题 SSH延迟加载导致的无法删除和修改的问题 来看看这个需求能实现不,来的都发财
不知道Lzy的展示页面时用什么写的
<!-- 欢迎界面-->
<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
<!-- 欢迎界面-->
<welcome-file-list>
<welcome-file>/web/my.jsp.</welcome-file>
</welcome-file-list>
重定向:response.sendRedirect("输入你要转发的网址名")
setTimeout("javascript:location.href='http://***'", 0);
</script> 在http://**** 页面中加上个跳转代码<%
response.sendRedirect(request.getContextPath() + "/web/my.jsp");
%>
1:请求转发
2:重定向
3:javascript