How do I set software cookies using Crosswalk XWalkView?

I need to make a webview application that POSTs the username and password and then displays the webpage logged. I have to use cookies but I couldn't find how to do it, tried traditional ways but nothing.

Anyone have any experience with xWalkView and how to get / set cookies?

(I am using xWalkView as traditional webview on Android 4.2.2 cannot load HTML5 web pages)

+3


source to share


1 answer


I had the same problem but couldn't find the exact answer. I found a job instead. Since I am using a servlet container, I add "; jsessionid =" to every request I make to the server. Another thing that might actually work for you, no matter what backend you are using, is to make a request to your web server to return a response with a cookie. For example, if you want to add name = test, you can make some xhr request to some url, and the response should contain the cookie name = test in it. This method also works for me for session tracking in my java application. Good luck.



0


source







All Articles