You Are Here:

Community: Wiki

 

Talk:HTTP Post multipart file upload in Java ME

From Forum Nokia Wiki

this piece of code works great, but i am having a little problem the HttpConnection its not Setting the Content-Lenght and the transfer its being made with transfer-encodign: chunked

i dont know if tha later is giving problems but the thing about the content-lenght its giving some problems with a server with mod_sec that its forbiding REQUEST without Content-Lenght header so im getting a 403 its there any way to set the content-Lenght? setRequestParameter() i think is not working thanks in adavance

Maximum file size that can be uploaded from mobile

I tried the same example. I am able to upload file which are less than 150 bytes. If I upload the file more than that size I get the following error. Please help me in this

java.io.IOException: error 104 during TCP read

       at com.sun.midp.io.j2me.socket.Protocol.nonBufferedRead(Protocol.java:299)
       at com.sun.midp.io.BufferedConnectionAdapter.readBytes(BufferedConnectionAdapter.java:99)
       at com.sun.midp.io.BaseInputStream.read(ConnectionBaseAdapter.java:582)
       at com.sun.midp.io.BaseInputStream.read(ConnectionBaseAdapter.java:511)
       at java.io.DataInputStream.read(+7)
       at com.sun.midp.io.j2me.http.Protocol.readLine(+4)
       at com.sun.midp.io.j2me.http.Protocol.readResponseMessage(+17)
       at com.sun.midp.io.j2me.http.Protocol.finishRequestGetResponseHeader(+39)
       at com.sun.midp.io.j2me.http.Protocol.sendRequest(+50)
       at com.sun.midp.io.j2me.http.Protocol.sendRequest(+6)
       at com.sun.midp.io.j2me.http.Protocol.closeOutputStream(+4)
       at com.sun.midp.io.BaseOutputStream.close(ConnectionBaseAdapter.java:737)
       at hello.HttpMultipartRequest.send(HttpMultipartRequest.java:91)
       at hello.PostMIDlet.run(PostMIDlet.java:104)


Thanks in advance Smith, http://www.samudhai.com

Nokia 6300 and J2ME problems

I made MIDDLET which is capable of working to Semens CX75. (Very old!) My MIDDLET create photo and send it to site by HTTP. But "Nokia 6300" reject my MIDDLET.

Help me!

(1) I find sample: HTTP Post multipart file upload with J2ME [1] But it is not an example. It is a hint. It cannot be compiled!

Show to us an example which is compiled by WTK2.5.2 and carried out by Nokia S40 devices.

(2) Show to us an prescription which should compile WTK2.5.2 MIDDLETs examples for Nokia S40 devices. (In particular "CameraDemo" and HttpConnection-samples.)

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia 
RDF Facets: qdcZidentifierQSxhttpE3aE2fE2fwikiE2eforumE2enokiaE2ecomE2findeE78E2ephpE2fHttpE3aE2fE2f217E2e218E2e225E2e2E3a2082E2findeE78E2ehtmlE253FX qdcZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qdcZtypeQUqfntypeZCommunityContentQ qdcZtypeQUqfntypeZE52esourceQ qdcZtypeQUqfntypeZWebpageQ qdcZtypeQUqfntypeZWikiContentQ qdcZtypeQUqmarsZManagedE52esourceQ qdcZtypeQUqwebZInformationE52esourceQ qdcZtypeQUqwebZPageQ qdcZtypeQUqwebZE52esourceQ qdcZtypeQUqrdfsZE52esourceQ qfnZtypeQUqfntypeZCommunityContentQ qfnZtypeQUqfntypeZE52esourceQ qfnZtypeQUqfntypeZWebpageQ qfnZtypeQUqfntypeZWikiContentQ qmarsZlanguageQUxhttpE3aE2fE2fswE2enokiaE2ecomE2flanguageE2d1E2fenX qrdfZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qrdfZtypeQUqfntypeZCommunityContentQ qrdfZtypeQUqfntypeZE52esourceQ qrdfZtypeQUqfntypeZWebpageQ qrdfZtypeQUqfntypeZWikiContentQ qrdfZtypeQUqmarsZManagedE52esourceQ qrdfZtypeQUqwebZInformationE52esourceQ qrdfZtypeQUqwebZPageQ qrdfZtypeQUqwebZE52esourceQ qrdfZtypeQUqrdfsZE52esourceQ