Http POST with Login

GaNdAlF89

Active Member
Licensed User
Longtime User
In my app I need something like a mini-browser, where the user login with username and password. I thought to do this:

B4X:
Dim MyUrl As String
Dim myHttpRequest As HttpRequest
MyUrl = "https://MyURL.php"
Dim MyStr() As Byte
Dim data As String
data = "user=1234&pass=5678"
MyStr = data.GetBytes("UTF8")
myHttpRequest.InitializePost2(MyUrl,MyStr)

This is correct?

And, how can I show the page after login (with a WebView)?
 

grant1842

Active Member
Licensed User
Longtime User
You'll want to use the httputils2 class found on the forum.
 
Upvote 0
Top