使用springmvc时报错HTTP Status 400 -

这个错误大多是因为,jsp的form表单提交的字段类型后台接收字段类型不匹配造成的(例如,form中为String,后台接收为Integer)。

我这里就是jsp表单中的日期数据没有写明类型,然后用Date接收就报错,把javabean中的Date类型换成String就没有错了。

原文地址:https://www.cnblogs.com/liaoxiaolao/p/10010337.html

时间: 2024-08-01 00:04:10

使用springmvc时报错HTTP Status 400 -的相关文章

使用SpringMVC时报错HTTP Status 405 - Request method 'GET' not supported

GET方法不支持.我出错的原因在于,在JSP中我希望超链接a以post方式提交,但是这里写js代码时出错. <script type="text/javascript"> $(function(){ $(".delete").click(function(){ var href = $(this).attr("href"); $("form").attr("action",href).submi

使用springmvc时报错JSPs only permit GET POST or HEAD

两个地方需要注意:第一处在web.xml文件中不要忘记配置 <filter> <filter-name>HiddenHttpMethodFilter</filter-name> <filter-class>org.springframework.web.filter.HiddenHttpMethodFilter</filter-class> </filter> <filter-mapping> <filter-nam

springMVC 文件上传 HTTP Status 400 – Bad Request

可能原因是:multipartResolver没有配置正确 请看解决方案: <!--文件上传 id必须为multipartResolver,不然报错HTTP Status 400 – Bad Request--> <bean id="multipartResolver" class="org.springframework.web.multipart.commons.CommonsMultipartResolver"> <propert

安装Python的psutil模块时报错:error: command &#39;gcc&#39; failed with exit status 1

安装Python的psutil模块: tar zxvf psutil-2.0.0.tar.gz cd psutil-2.0.0 python setup.py install 报错: running install running bdist_egg ...... psutil/_psutil_linux.c:12:20: error: Python.h: No such file or directory In file included from psutil/_psutil_linux.c

安装cx_Oracle时报错:error: command &#39;gcc&#39; failed with exit status 1

1.安装cx_Oracle 1)下载cx_Oracle,https://pypi.python.org/pypi 2)解压压缩包 3)执行python setup.py install 执行后报错:error: command 'gcc' failed with exit status 1 排查: 1)检查是否安装oracle客户端软件 2)查看当前环境变量中是否配置oracle的相关变量,如echo $ORACLE_HOME 3)如果没有配置需要将oracle环境变量配置到当前用户.bash_

HTTP Status 415 HTTP Status 400 Post @requestbody Springmvc

1,先说一下自己的问题,用postman测试数据 <html> <head> <title>Apache Tomcat/7.0.59 - Error report</title> <style> <!--H1 {font-family:Tahoma,Arial,sans-serif;color:white;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white

SpringMVC在使用JSON时报错信息为:Content type &#39;application/json;charset=UTF-8&#39; not supported

直接原因是:我的(maven)项目parent父工程pom.xml缺少必要的三个jar包依赖坐标. 解决方法是:在web子模块的pom.xml里面添加springMVC使用JSON实现AJAX请求. <!--spring mvc-json依赖--> <dependency> <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-databind</artifact

Spring MVC,HTTP Status 400 ,jQuery

一.先看下4xx错误的说明 [转载] http status 400,http 400,400 错误 [参考] status code 400, Bad Request (§10.4.1) 4 请求失败4xx 4xx应答定义了特定服务器响应的请求失败的情况.客户端不应当在不更改请求的情况下重新尝试同一个请求.(例如,增加合适的认证信息).不过,同一个请求交给不同服务器也许就会成功. 4.1 400 Bad Request 请求中的语法错误.Reason-Phrase应当标志这个详细的语法错误,比

apache添加模块时报错:module status_module is built-in and can&#39;t be loaded

在使用cacti监控linux主机上的apache时,apache需要加载 mod_status.so 模块. 编辑httpd.conf,手动添加下行: LoadModule status_module modules/mod_status.so 在重启apache时报错如下: httpd: Syntax error on line 58 of /etc/httpd/httpd.conf: module status_module is built-in and can't be loaded