页面html:
<form class="form-horizontal" id="form1" action="${cxt!}/ws/api/iotbusi/uploadfile2" enctype="multipart/form-data" method="POST">
报的错 :
java.lang.RuntimeException: java.io.IOException: Posted content type isn't multipart/form-data
at com.jfinal.upload.MultipartRequest.wrapMultipartRequest(MultipartRequest.java:123)
at com.jfinal.upload.MultipartRequest.<init>(MultipartRequest.java:68)
at com.jfinal.core.Controller.getFiles(Controller.java:767)
at com.jfinal.core.Controller.getFile(Controller.java:777)
at ws.iot.api.BusiController.uploadfile2(BusiController.java:255)
at sun.reflect.GeneratedMethodAccessor96.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.jfinal.aop.Invocation.invoke(Invocation.java:73)
at com.jfinal.i18n.I18nInterceptor.intercept(I18nInterceptor.java:106)
at com.jfinal.aop.Invocation.invoke(Invocation.java:67)
at com.jfinal.plugin.activerecord.tx.TxByActionKeyRegex.intercept(TxByActionKeyRegex.java:61)
at com.jfinal.aop.Invocation.invoke(Invocation.java:67)
at com.jfinal.plugin.activerecord.tx.TxByActionKeys.intercept(TxByActionKeys.java:57)
at com.jfinal.aop.Invocation.invoke(Invocation.java:67)
at com.jfinal.plugin.activerecord.tx.TxByMethodRegex.intercept(TxByMethodRegex.java:61)
at com.jfinal.aop.Invocation.invoke(Invocation.java:67)
at com.jfinal.plugin.activerecord.tx.TxByMethods.intercept(TxByMethods.java:57)
at com.jfinal.aop.Invocation.invoke(Invocation.java:67)
at ws.platform.interceptor.ParamPkgInterceptor.intercept(ParamPkgInterceptor.java:92)
at com.jfinal.aop.Invocation.invoke(Invocation.java:67)
at ws.platform.interceptor.AuthInterceptor.intercept(AuthInterceptor.java:73)
at com.jfinal.aop.Invocation.invoke(Invocation.java:67)
at com.jfinal.core.ActionHandler.handle(ActionHandler.java:82)
at ws.platform.handler.GlobalHandler.handle(GlobalHandler.java:84)
at com.jfinal.core.JFinalFilter.doFilter(JFinalFilter.java:77)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1652)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:585)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:577)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:223)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1127)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:515)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1061)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:215)
at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:110)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)
at org.eclipse.jetty.server.Server.handle(Server.java:497)
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:310)
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:257)
at org.eclipse.jetty.io.AbstractConnection$2.run(AbstractConnection.java:540)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635)
at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555)
at java.lang.Thread.run(Unknown Source)
Caused by: java.io.IOException: Posted content type isn't multipart/form-data
at com.oreilly.servlet.multipart.MultipartParser.<init>(MultipartParser.java:168)
at com.oreilly.servlet.MultipartRequest.<init>(MultipartRequest.java:223)
at com.jfinal.upload.MultipartRequest.wrapMultipartRequest(MultipartRequest.java:107)