• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Is it possible to directly in a txt file using HttpConnection without any servlet?

 
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am trying to write some text from midlet to a .txt file one the server.

I have already a file on the server named a.txt

Here is the code segment..

I don't know if this is a stupid question...
However any help is greatly appreciated.
 
Ranch Hand
Posts: 87
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Here you are sending a hello string to server for adding to a b.text file which is in the server.This is what I assumed.
For adding or editing in the text file which is in the server You have to write the procedure in the server side according to
your request in the mobile.
 
Olga Flasza
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, Thanks for the reply. your assumption is correct.

I have a very little experience on server side programming. Infact I am trying to upload an image on the server from MIDlet.

I am using PHP as server side language. I like to know that if it is possible to upload image using the POST method..

Can you please give me an example ?
 
Gopinath Karyadath
Ranch Hand
Posts: 87
 
Olga Flasza
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am sending images as byte Array (data[])
but not sure how to handle it in PHP..

From midlet I send through the stream as


Here is my PHP code...


On the midlet screen It prints error only..
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic