2 Replies Latest reply on Oct 2, 2011 6:04 AM by david77007

    I've lost my cookie!




      I would really appreciate help (i'm on my first week of flex so i apologize if my code is flawed) - i just cant figure this problem out.  I have a webservice (which i can access successfully) that requires a cookie to be resubmitted each time i make a request to it.



      var username:String = "admin";

      var password:String = "password"

      var cookie:String = srv.login.send(username,password,3600);



      When use a label and write to {srv.login.lastResult} - the token is written succesfully.  I'm trying to figure out how to store the value so that i can make new service requests with the value.  I've tried "localShareObject", but cant seem to get that to work.  Any help is GREATLY appreciated!






        • 1. Re: I've lost my cookie!
          Sathyamoorthi Level 2



          you don't need to do anything for it. It's a job of browser. It will maintain session id in cookie. For each and every request browser send session id.

          Thats fine enough for webservice.


          All you have to do is send user credentials at the beginning.

          • 2. Re: I've lost my cookie!
            david77007 Level 1

            That is fantastic to hear!  Wow!  well....last question?  is there a way to refer to this information?  My webservice (not one i created) is expecting the variable to be placed as a parameter in the request.  Is there an internal reference value that i can refer to (i'm new so i'm not sure i'm asking this correctly)


            thanks again!