Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android client server application [closed]

I want to create an android app which should be authenticated through the server. How can I code both client side and server side to make this possible ?

On the server side what should I use to do scripting and how ?

Flow should be like this:

  1. User enters it's username and password on the android app screen.
  2. These arg go to server where they are authenticated and response is returned to the android app.
like image 799
user2702891 Avatar asked Apr 09 '14 12:04

user2702891


2 Answers

For client side you send your request in json format(key value pair) and for server side (you can use either php or servlet ) and send the response ,in json format

Pleaes refer this link Android client server tutorial

like image 126
Trupti Avatar answered Oct 16 '22 12:10

Trupti


You should have provided more details such as what you have tried so far so that we can direct you further but still I will try to give you basic idea

1. design your layout for android in xml and then define the elements in your activity class. in your case it would simply be two edittext boxed and a button then check it if works

2. Which script to use for server side is upto your knowledge and proficiency and also depends upon you requirements. for basic apps you can use php. write the php script and setup your database against which you are planning to verify the args. if you are not sure this link will take you to very simple tutorial from which you can learn or you can use other tutorials from internet.

3. Once you are done with the setup you can use different methods to see the response from such as JSONresponse or simple echo/print methods.

4. after all this you can write a class or method on you client side once again to make Httprequest using Get or post method and see the response.

like image 2
madteapot Avatar answered Oct 16 '22 10:10

madteapot