How can I access the response headers in Android webview? I searched on Google there is some article about this, but they use OkHTTP
or custom HTTP request in shouldOverrideUrlLoading
, but I think we need to handle cookies and HTTP methods yourself. I just want to get the response headers.
Is there a simple way to do this? or is there any library for custom webview that I can use to achieve this?
There is a question related to this issue on StackOverflow, but as said he uses an HTTP request in shouldOverrideUrlLoading
to send a request to the URL and load the response data into webview.