锘??xml version="1.0" encoding="utf-8" standalone="yes"?>一区二区三区 在线观看视,国产精品久久久久国产精品日日,久99久在线视频http://www.aygfsteel.com/liangj/category/30378.htmlzh-cnWed, 26 Mar 2008 03:05:59 GMTWed, 26 Mar 2008 03:05:59 GMT60瑙e喅褰揊ORM鐨凟NCTYPE="multipart/form-data" 鏃秗equest.getParameter()鑾峰彇涓嶅埌鍊肩殑鏂規(guī)硶http://www.aygfsteel.com/liangj/archive/2008/03/26/188666.html姊佸仴姊佸仴Wed, 26 Mar 2008 02:38:00 GMThttp://www.aygfsteel.com/liangj/archive/2008/03/26/188666.htmlhttp://www.aygfsteel.com/liangj/comments/188666.htmlhttp://www.aygfsteel.com/liangj/archive/2008/03/26/188666.html#Feedback0http://www.aygfsteel.com/liangj/comments/commentRss/188666.htmlhttp://www.aygfsteel.com/liangj/services/trackbacks/188666.htmlSituation(鍘熷洜):
    javax.servlet.HttpServletRequest.getParameter(String) returns null when the ContentType is multipart/form-data

Solutions(瑙e喅鍔炴硶):
  • Solution A: 
    1. download http://www.servlets.com/cos/index.html
    2. invoke getParameters() on com.oreilly.servlet.MultipartRequest
  • Solution B:
    1. download http://jakarta.apache.org/commons/fileupload/ 
    2. invoke readHeaders() in org.apache.commons.fileupload.MultipartStream
    Or
    1. Invoke parseRequest(request) on org.apache.commons.fileupload.FileUploadBase which returns list of org.apache.commons.fileupload.FileItem objects.
   2. Invoke isFormField() on each of the FileItem objects. This determines whether the file item is a form paramater or stream of uploaded file.
   3. Invoke getFieldName() to get parameter name and getString() to get parameter value on FileItem if it's a form parameter. Invoke write(java.io.File) on FileItem to save the uploaded file stream to a file if the FileItem is not a form parameter.

  • Solution C:
    1. download http://users.boone.net/wbrameld/multipartformdata/
    2. invoke getParameter on com.bigfoot.bugar.servlet.http.MultipartFormData
  • Solution D:
    Use Struts. Struts 1.1 handles this automatically.


姊佸仴 2008-03-26 10:38 鍙戣〃璇勮
]]>
主站蜘蛛池模板: 莆田市| 平度市| 将乐县| 枝江市| 永新县| 青川县| 平遥县| 武鸣县| 桂阳县| 沾益县| 冕宁县| 新田县| 中方县| 虞城县| 北流市| 禹城市| 东乡县| 怀来县| 景宁| 广水市| 德清县| 温宿县| 始兴县| 温州市| 贵州省| 泰顺县| 大英县| 蛟河市| 长寿区| 务川| 定远县| 新龙县| 乌苏市| 邢台市| 临泉县| 鸡西市| 海城市| 长宁区| 锡林郭勒盟| 江门市| 刚察县|