LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   phonegap / android - xmlhttprequest going out with different cookies (https://www.linuxquestions.org/questions/programming-9/phonegap-android-xmlhttprequest-going-out-with-different-cookies-946518/)

eantoranz 05-23-2012 03:51 PM

phonegap / android - xmlhttprequest going out with different cookies
 
Hi, guys!

I just nailed a problem that I don't know how to solve.

I started developing a Phonegap application using android 4. I hit a bug related to iframe parents so I switched back to 2.1.

In android 4, when I was going to make an xmlhttprequest, I had to set up the Cookies for connecting to a remote PHP application by hand..... but I just noticed that xmlhttprequests are going out with Cookies set in android 2.1.... the problem is that for two different pages in my application, cookies are being set differently and so I don't get the right $_SESSION information when doing a request..... So, I have two questions:

1 - Why is that?
2 - How can I trick the xmlhttprequest to use a custom cookie instead of the ones created "by default"?

eantoranz 05-23-2012 04:22 PM

Totally crazy stuff. I had to remove the cache in order for the application to use the same cookie.


All times are GMT -5. The time now is 08:05 PM.