#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2003
    Posts
    10
    Rep Power
    0

    Save information of session in txt file


    I want to save the session content
    (cart shopping information: items, qty, etc.)
    in a txt file.
    I want to do it with a servlet. How can do it?
  2. #2
  3. No Profile Picture
    Clueless llama
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Feb 2001
    Location
    Lincoln, NE. USA
    Posts
    2,353
    Rep Power
    117
    You'd be saving this text file on the server, is that what you want? And in what format do you want to save this info? Human readable or as something the jvm can make back into objects? What code do you have so far?
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2003
    Posts
    10
    Rep Power
    0
    You'd be saving this text file on the server, is that what you want? And in what format do you want to save this info? Human readable or as something the jvm can make back into objects? What code do you have so far?

    I want a txt file. For axample:

    Order: 12000
    Name: JC
    Article: Book
    Price: 12E
  6. #4
  7. No Profile Picture
    Clueless llama
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Feb 2001
    Location
    Lincoln, NE. USA
    Posts
    2,353
    Rep Power
    117
    I'm sorry, you did not answer all of my questions. Do you want this file saved on the server then? What code do you have so far, anything? or were you wanting someone to show you how to do it from start to finish?
  8. #5
  9. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2003
    Posts
    10
    Rep Power
    0
    Do you want this file saved on the server then?
    - Yes

    The content of the file have to be the content of the cart.
  10. #6
  11. No Profile Picture
    Clueless llama
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Feb 2001
    Location
    Lincoln, NE. USA
    Posts
    2,353
    Rep Power
    117
    You need to create a file using a stream.

    FileStream

    Streams

IMN logo majestic logo threadwatch logo seochat tools logo