错误:“The requested resource () is not available.”的处置
做网页过程中,某页需要以新窗方式打开另一个网页,于是url是这样写:
pages/test/transw/claimer.html
但是,点链接后网页提示
The requested resource () is not available.
再检查一遍url,没有发现拼写错误。
郁闷一阵,看看后缀,明白了,claimer.html的后缀是html,这和Web.xml中设置的url-pattern对应上了:
<servlet>
<servlet-name>spring</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>spring</servlet-name>
<url-pattern>*.html</url-pattern>
</servlet-mapping>
这个阴差阳错的对应照成了,本该去找静态网页的链接,变成交给sping处理了,而spring的controller里是没有对应处理函数的。
难怪系统报The requested resource () is not available.错。
处置方式也简单,将静态文件名修改成claimer.htm,少写一个l。这样就不会让spring mvc去处理了。
然后链接地址就这样写:
pages/test/transw/claimer.htm
错误:“The requested resource () is not available.”的处置的更多相关文章
- ajax请求node.js接口时出现 No 'Access-Control-Allow-Origin' header is present on the requested resource错误
ajax请求node.js接口出现了如下的错误: XMLHttpRequest cannot load http://xxx.xxx.xx.xx:8888/getTem?cityId=110105&a ...
- As.net WebAPI CORS, 开启跨源访问,解决错误No 'Access-Control-Allow-Origin' header is present on the requested resource
默认情况下ajax请求是有同源策略,限制了不同域请求的响应. 例子:http://localhost:23160/HtmlPage.html 请求不同源API http://localhost:228 ...
- 【转】tomcat 访问软连接文件夹下的网页出现404错误,description The requested resource (/xxx.html) is not available.
在 tomcat/webapps/ROOT/ 下建立一个软连接文件ln -s /home/ubuntu/report report 再到report软连接目录里建立个 report.html通过浏 ...
- ABP PUT、DELETE请求错误405.0 - Method Not Allowed 因为使用了无效方法(HTTP 谓词) 引发客户端错误 No 'Access-Control-Allow-Origin' header is present on the requested resource
先请检查是否是跨域配置问题,请参考博客:http://www.cnblogs.com/donaldtdz/p/7882225.html 一.问题描述 ABP angular前端部署后,查询,新增都没问 ...
- Webapi 跨域 解决解决错误No 'Access-Control-Allow-Origin' header is present on the requested resource 问题
首先是web端(http://localhost:53784) 请求 api(http://localhost:81/api/)时出现错误信息: 查看控制台会发现错误:XMLHttpRequest c ...
- 解决Tomcat错误信息:No 'Access-Control-Allow-Origin' header is present on the requested resource | Solving Tomcat Error: No 'Access-Control-Allow-Origin' header is present on the requested resource
最近在使用GeoServer调用Vector Tile服务时,经常会显示不出来结果.打开浏览器调试台,发现报No 'Access-Control-Allow-Origin' header is pre ...
- Servlet中The requested resource is not available错误
自己为了测试servlet,用MyEclipse2015写了一个简单的登录程序. 1.登录页面index.jsp. <%@ page language="java" impo ...
- js跨域访问,No 'Access-Control-Allow-Origin' header is present on the requested resource
js跨域访问提示错误:XMLHttpRequest cannot load http://...... No 'Access-Control-Allow-Origin' header is prese ...
- The requested resource is not available...
运行tomcat 提示如下错误: The requested resource () is not available的解决方案 出现这个问题,接口肯定是没问题了.问题可能有两个: 1.文件设置无法访 ...
随机推荐
- Linux环境准备20160921
这篇文章,是我准备linux的java环境时候,碰到的各种问题,采用的是centos 6.5版本. 1.卸载open jdk 先查看 rpm -qa | grep java # java-1.4. ...
- d3.js path路径
转自:http://www.d3js.cn/?p=68 svg的path标签被称为”可以组成任何形状的形状” SVG Path可以绘制任何形状的图形,包括矩形,圆形,椭圆,折线,多边形,直线,曲线等. ...
- hdu 4359 dp
/* 题目大意:给n个节点的二叉树第i个节点的权值为2^(i-1), 求所有含左右子树的节点都符合左子树的权和小于右子树权和的种数. */ #include <iostream> #inc ...
- Bzoj3093 [Fdu校赛2012] A Famous Game
Time Limit: 1 Sec Memory Limit: 128 MBSubmit: 251 Solved: 136 Description Mr. B and Mr. M like to ...
- OpenCV 2.4.9 学习笔记(3)—— OpenCV自动为输出数组(矩阵)分配内存
OpenCV大部分时候会为OpenCV方法中的输出数据(方法的参数)自动分配内存,所以如果一个方法的参数有一个或者多个输入数组(cv::Mat 实例)和一些输出数组时,OpenCV会自动为输出数组分配 ...
- 转载:C++ 多继承和虚继承的内存布局
C++ 多继承和虚继承的内存布局[已翻译100%] 英文原文:Memory Layout for Multiple and Virtual Inheritance 标签: <无> run_ ...
- iOS_自定义毛玻璃效果
http://www.2cto.com/kf/201408/329969.html 最终效果图: 关键代码: UIImage分类代码 ? 1 2 3 4 5 6 7 8 9 10 11 12 13 1 ...
- Synthesis of memory barriers
A framework is provided for automatic inference of memory fences in concurrent programs. A method is ...
- Error:Execution failed for task ':app:transformClassesWithDexForDebug'. > com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: java.util.concurrent.Exec
Error:Execution failed for task ':app:transformClassesWithDexForDebug'.> com.android.build.api.tr ...
- 在C#中调用格式工厂进行任意视频格式到FLV的转换
1.下载安装格式工厂和完美解码器 2.运行格式工厂,转换一个RMVB到FLV,注意找个大点的,使时间长一些.防止在未执行步骤3时就结束了 3.在进程中查看某个进程的命令行参数是什么? wmic pro ...