错误The request sent by the client was syntactically incorrect ()的解决
http://www.cnblogs.com/xiandedanteng/p/4168609.html
这个错误是SpringMVC报出来的,见到它意味着html/jsp页面的控件名称 和 controller里函数的参数不符。

好比界面有个这样的form
<form name="form1" action="uploadDocument.html" method="post" ENCTYPE="multipart/form-data">
<div class="form" >
<p>
<span class="req"><input id="remarkTxt" name="remarkTxt" class="field size4" title="Enter the date" /></span>
<label>Remark: <span>(The brief introduction of the file)</span></label>
</p> <p>
<span class="req"><input type="file" name="uploadFileCtrl" class="field size4" title="Choose the file" /></span>
<label>Upload file: <span>(Click browse to choose)</span></label>
</p>
</div> <div class="buttons">
<input id="queryBtn" type="button" class="button" value="Submit" />
</div> </form>
而对应的函数参数应该这样写:
@RequestMapping(value="/uploadDocument")
public String uploadDocument( @RequestParam("remarkTxt") String remark,
@RequestParam("uploadFileCtrl") MultipartFile file,
HttpServletRequest request,
HttpServletResponse response){
....
}
}
错误The request sent by the client was syntactically incorrect ()的解决的更多相关文章
- 错误:The request sent by the client was syntactically incorrect的解决
问题: 错误400-The request sent by the client was syntactically incorrect. springMVC中,某个页面提交时报400错误,如下图. ...
- SpringMVC---400错误The request sent by the client was syntactically incorrect ()
在SpringMVC中使用@RequestBody和@ModelAttribute注解时遇到了很多问题,现记录下来. @ModelAttribute这个注解主要是将客户端请求的参数绑定参数到一个对象上 ...
- 错误400-The request sent by the client was syntactically incorrect
springMVC中,某个页面提交时报400错误,如下图. 解决方法: 1.在网上找了一下,答案是通常遇到这个错误是因为前端jsp页面的控件名称和controller中接收的参数名称不一致.但 ...
- SpringMVC报错The request sent by the client was syntactically incorrect ()
springmvc数据绑定出的错 在数据绑定的时候一定要主意Controller方法中的参数名和jsp页面里的参数名字是否一致或者按照绑定的规范来写, 如果不一致,可能回报如下错误: The requ ...
- The request sent by the client was syntactically incorrect.
HTTP Status 400 - type Status report message description The request sent by the client was syntacti ...
- 又见The request sent by the client was syntactically incorrect ()
前几天遇到过这个问题(Ref:http://www.cnblogs.com/xiandedanteng/p/4168609.html),问题在页面的组件name和和注解的@param名匹配不对,这个好 ...
- "The request sent by the client was syntactically incorrect ()"问题定位及解决:
Spring MVC "The request sent by the client was syntactically incorrect ()"解决办法: 把spring日志级 ...
- The request sent by the client was syntactically incorrect问题解决
The request sent by the client was syntactically incorrect意思嘛,google翻译一下 通过日志不难看出,是由参数不匹配造成的. 所以对于Da ...
- spring mvc 在上传图片时,浏览器报The request sent by the client was syntactically incorrect
项目中,在一个jsp页面里其它图片上传是功能是可以使用的,当我自己新加了一个图片上传时,提交表单后,浏览器报The request sent by the client was syntactical ...
随机推荐
- 如何异步创建文件夹(node)
模块fs作为node的核心模块之一,支持本地文件操作的接口,几乎对于所有的操作都提供同步和异步两种方案.例如,创建文件夹有mkdir和mkdirSync.不论对于mkdir还是mkdirSync,都需 ...
- Spring 依赖注入的方式
Spring 支持3中依赖注入的方式 1.属性注入 通过setter 方法注入Bean的属性或依赖的对象. <bean id = " " class = " &q ...
- 在Mac上安装IntelliJ IDEA
这篇文章旨在介绍如何在Mac系统上安装IntelliJ IDEA,至于IntelliJ IDEA的介绍和使用方法,大家另行查阅,本篇的文章不再详细阐述. 简短解说,IntelliJ IDEA是可以用来 ...
- .NET Remoting原理及应用实例:
Remoting:(本文摘自百度百科) 简介: 什么是Remoting,简而言之,我们可以将其看作是一种分布式处理方 式.从微软的产品角度来看,可以说Remoting就是DCOM的一种升 ...
- 使用GITHUB的体会
github的网页链接 https://github.com/zhangji123/test 学习总结 通过学习使用github软件使我掌握了其使用方法及其独特之处 1.github的网址: htt ...
- HTTP请求响应对照表
1)请求(客户端->服务端[request]) GET(请求的方式) /books/java.html(请求的目标资源) HTTP/1.1(请求采用的协议和版本号) Accept: */*(客户 ...
- 修改ubuntu DNS的步骤(图文)
有时候连接上VPN服务器后,还是打不开某些网站,这时候,需要对DNS进行更改,一般是修改成为谷歌提供的免费DNS:8.8.8.8 8.8.4.4,在windows下更改比较简单(点击查看“连接上VP ...
- Linux内核实现中断和中断处理(二)
第一部分移步传送门召唤!!:http://www.cnblogs.com/lenomirei/p/5562086.html 上回说了Linux内核实现中断会把中断分为两部分进行处理,上回讲了上部分,这 ...
- Unity5 如何做资源管理和增量更新
工具 Unity 中的资源来源有三个途径:一个是Unity自动打包资源,一个是Resources,一个是AssetBundle. Unity自动打包资源是指在Unity场景中直接使用到的资源会随着场景 ...
- 20145301&20145321&20145335实验一
这次实验我的组员为:20145301赵嘉鑫.20145321曾子誉.20145335郝昊 实验内容详见:实验一报告