疯狂

STANDING ON THE SHOULDERS OF GIANTS
posts - 481, comments - 486, trackbacks - 0, articles - 1
  BlogJava :: 首页 :: 新随笔 :: 联系 :: 聚合  :: 管理
  需要的包,commons-fileupload.jar,commons-io-1.3.2.jar,multipartrequest.jar都有
配置:
webwork.i18n.encoding=UTF-8
webwork.i18n.reload=false
webwork.multipart.maxSize=2097152
webwork.multipart.parser=jakarta
webwork.multipart.saveDir=/tmp
webwork.tag.altSyntax=true
还有:
<action name="toupload" class="UP" method="startUpLoad" >
      <interceptor-ref name="fileUpload"></interceptor-ref>
   <result name="success" type="velocity">/com/bjnv/client/fileload/action/pages/success.vm</result>
   <result name="fail" type="velocity">/com/bjnv/client/fileload/action/pages/fail.vm</result>
  </action>
-----------------------------------------------
报错:
2008-1-21 11:31:08 org.mortbay.jetty.servlet.ServletHandler handle
警告: Error for /load/toupload!startUpLoad.action
java.lang.NoClassDefFoundError: org/apache/commons/fileupload/RequestContext
 at java.lang.Class.getDeclaredConstructors0(Native Method)
 at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
 at java.lang.Class.getConstructor0(Class.java:2699)
 at java.lang.Class.getDeclaredConstructor(Class.java:1985)
 at com.opensymphony.webwork.dispatcher.multipart.MultiPartRequestWrapper.<init>(MultiPartRequestWrapper.java:89)
 at com.opensymphony.webwork.dispatcher.DispatcherUtils.wrapRequest(DispatcherUtils.java:490)
 at com.opensymphony.webwork.dispatcher.ServletDispatcher.service(ServletDispatcher.java:94)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
 at org.eclipse.equinox.http.servlet.internal.ServletRegistration.handleRequest(ServletRegistration.java:90)
 at org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:111)
 at org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:67)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
 at org.eclipse.equinox.http.jetty.internal.HttpServerManager$InternalHttpServiceServlet.service(HttpServerManager.java:288)
 at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:428)
 at org.mortbay.jetty.servlet.ServletHandler.dispatch(ServletHandler.java:677)
 at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:568)
 at org.mortbay.http.HttpContext.handle(HttpContext.java:1530)
 at org.mortbay.http.HttpContext.handle(HttpContext.java:1482)
 at org.mortbay.http.HttpServer.service(HttpServer.java:909)
 at org.mortbay.http.HttpConnection.service(HttpConnection.java:820)
 at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:986)
 at org.mortbay.http.HttpConnection.handle(HttpConnection.java:837)
 at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:245)
 at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:357)
 at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:534)

只有注册用户登录后才能发表评论。


网站导航: