配置SSH遇到的问题,求解

土---豆 2013-08-09 10:32:19
在学习ssh架构的时候遇到下面问题:
这是web.xml文件
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5"
xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
<filter>
<filter-name>struts2</filter-name>
<filter-class>
org.apache.struts2.dispatcher.FilterDispatcher
</filter-class>
</filter>
<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>*.action</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>*.jsp</url-pattern>
</filter-mapping>
<filter>
<filter-name>struts-cleanup</filter-name>
<filter-class>org.apache.struts2.views.jsp.ui.AnchorTag</filter-class>
</filter>

<filter-mapping>
<filter-name>struts-cleanup</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>

<listener>
<listener-class>
org.springframework.web.context.ContextLoaderListener
</listener-class>
</listener>
</web-app>



这是index.jsp文件
<%@ page language="java" import="java.util.*" pageEncoding="ISO-8859-1"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<%@ taglib prefix="s" uri="/struts-tags" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">

<title>My JSP 'index.jsp' starting page</title>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">
<!--
<link rel="stylesheet" type="text/css" href="styles.css">
-->
</head>

<body>
<h1><font color="red">Operate List</font></h1>
<s:a href="save.jsp">Save User</s:a><br><br><br>
<s:a href="listUser.action">List Users</s:a>
</body>
</html>
<s:a>标签前面有小感叹号
运行的时候出现404错误



但是刚刚搭建好的ssh架构,运行index.jsp是没有任何问题的,准备加点代码,结果就成了这样,求大神解答!!!万分感激
...全文
148 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
街头小贩 2013-08-09
  • 打赏
  • 举报
回复
listUser.action re: 这个在哪里配置的呀
土---豆 2013-08-09
  • 打赏
  • 举报
回复
引用 3 楼 xiaofanku 的回复:
[quote=引用 2 楼 u011636309 的回复:] [quote=引用 1 楼 xiaofanku 的回复:] listUser.action re: 这个在哪里配置的呀
配置文件里没有listUser.action啊,这个是网页里要显示的链接!!!![/quote] 你换个http://www.bing.com或其它静态连接试试[/quote] 你的意思是链接的问题,我试试,但是不应该啊,在配置SSH之前程序时可以正常运行的!!!
街头小贩 2013-08-09
  • 打赏
  • 举报
回复
引用 2 楼 u011636309 的回复:
[quote=引用 1 楼 xiaofanku 的回复:] listUser.action re: 这个在哪里配置的呀
配置文件里没有listUser.action啊,这个是网页里要显示的链接!!!![/quote] 你换个http://www.bing.com或其它静态连接试试
土---豆 2013-08-09
  • 打赏
  • 举报
回复
引用 1 楼 xiaofanku 的回复:
listUser.action re: 这个在哪里配置的呀
配置文件里没有listUser.action啊,这个是网页里要显示的链接!!!!

8,906

社区成员

发帖
与我相关
我的任务
社区描述
XML/XSL相关问题讨论专区
社区管理员
  • XML/XSL社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧