Android developed an example of a login method

  • 2020-06-07 05:15:51
  • OfStack

As described in this paper, the method of sending data from Android to the server is continued in the previous article, and the method of registration and login is improved in step 1. Due to the version problem, there is one flaw, which has been solved after debugging today. Here, I will introduce 1 to you.

In Android4. 0 later become strict for Internet access, on the mentioned in article 1 case unable to send data to the server, when you click send data, 1 Android console will be an error, error is of course very troubling, is essentially about http mistakes, so you can be sure is Android appeared when the virtual machine to the server sends data error, just know, after 1 inspection and testing after 4.0 version, the main thread is not allowed to call in the network, if you need, Another thread should process the network connection Thread(new Runable(){private void run{then call the network connection}} in the run method.

You can also do this by resetting the Android version under 1 in AndroidManifest.xml:

    android:targetSdkVersion="8" />

With the above two methods, I believe you must have a better understanding of the Android access server.

Hopefully, the examples in this article have been helpful for your Android web application development.

Related articles: