1.在开发过程中遇到了需要接收数组参数的问题,在网上找了许多方法还是报错非法字符的问题,恳请各位大佬解惑。2.由于自己用是STS,内嵌tomcat9,已经尝试过了配置tomcat文件的方式3.相关代码(1)控制台错误报错java.lang.IllegalArgumentException:Invalidcharacterfoundintherequesttarget.ThevalidcharactersaredefinedinRFC7230andRFC3986atorg.apache.coyote.http11.Http11InputBuffer.parseRequestLine(Http11InputBuffer.java:479)~[tomcat-embed-core-8.5.34.jar:8.5.34](2)postman输入的urlhttp://192.168.0.182:8088/Artilce/batchDelete?arrs[0]=1&arrs[1]=2(3)controller方法@RequestMapping(value="/batchDelete",method=RequestMethod.POST)publicbooleanbatchDelete(@RequestParam(value="arrs[]")Integer[]arrs){for(inti=0;iSystem.out.println(arrs[i].toString()); }returntrue;}4.恳请大佬们解惑
缥缈止盈
相关分类