4. Creating the Android Project
The app we’re gonna build will have three simple screens Login Screen, Registration Screen and a welcome Dashboard Screen.
1. In Android Studio, create a new project from File ⇒ New Project and fill all the required details.
more details go to Create Android Project.
2. Open build.gradle and add volley library support by adding
compile ‘com.android.volley:volley:1.0.0’ under dependencies.
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:appcompat-v7:23.4.0'
compile 'com.android.support:design:23.4.0'
compile 'com.android.volley:volley:1.0.0'
}
3. Open strings.xml located under res ⇒ values and add below string values.
<resources>
<string name="app_name">My Application</string>
<string name="hint_email">Email</string>
<string name="hint_password">Password</string>
<string name="hint_name">Fullname</string>
<string name="login">Login</string>
<string name="register">Register</string>
<string name="btn_link_to_register">Not a member? Sign up now.</string>
<string name="btn_link_to_login">Already registred! Login Me.</string>
<string name="welcome">Welcome</string>
</resources>
4. Open colors.xml located under res ⇒ values and add the color values. If you don’t find colors.xml, create a new file with the name.
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="colorPrimary">#3F51B5</color>
<color name="colorPrimaryDark">#303F9F</color>
<color name="colorAccent">#FF4081</color>
<color name="white">#ffffff</color>
</resources>
5. Create a class named MyApplication.java. This class extends from Application which should be executed on app launch. In this class we initiate all the volley core objects.
package akraj.snow.app;
import android.app.Application;
import android.text.TextUtils;
import com.android.volley.Request;
import com.android.volley.RequestQueue;
import com.android.volley.toolbox.Volley;
/**
* Created by Akshay Raj on 6/16/2016.
*/
public class MyApplication extends Application {
public static final String TAG = MyApplication.class.getSimpleName();
private RequestQueue mRequestQueue;
private static MyApplication mInstance;
@Override
public void onCreate() {
super.onCreate();
mInstance = this;
}
public static synchronized MyApplication getInstance() {
return mInstance;
}
public RequestQueue getRequestQueue() {
if (mRequestQueue == null) {
mRequestQueue = Volley.newRequestQueue(getApplicationContext());
}
return mRequestQueue;
}
public <T> void addToRequestQueue(Request<T> req, String tag) {
req.setTag(TextUtils.isEmpty(tag) ? TAG : tag);
getRequestQueue().add(req);
}
public <T> void addToRequestQueue(Request<T> req) {
req.setTag(TAG);
getRequestQueue().add(req);
}
public void cancelPendingRequests(Object tag) {
if (mRequestQueue != null) {
mRequestQueue.cancelAll(tag);
}
}
}
6. Now open AndroidManifest.xml and add INTERNET permission. Add the MyApplication class to<application> tag. Also add other activities (LoginActivity, RegisterActivity and MainActivity) which we are going to create shortly. I am keeping LoginActivity as launcher activity as it should be seen on app launch.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.circleeduventures.app"
android:versionCode="2"
android:versionName="1.0.0.2">
<uses-sdk
android:minSdkVersion="15"
android:targetSdkVersion="23" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<application
android:name=".MyApplication"
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme">
<!-- Login Activity -->
<activity
android:name=".LoginActivity"
android:configChanges="orientation|screenSize"
android:label="@string/app_name"
android:screenOrientation="portrait">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<!-- Main Activity -->
<activity
android:name=".MainActivity"
android:label="@string/app_name"
android:screenOrientation="portrait">
</activity>
<!-- Register Activity -->
<activity
android:name=".RegisterActivity"
android:label="@string/app_name"
android:screenOrientation="portrait">
</activity>
</application>
</manifest>
4.1 Adding the Login Screen
Now we’ll implement the login module by creating the screen and adding the code to make login request to php, mysql server.
7. Create an xml file named activity_login.xml under res ⇒ layout.
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:padding="10dp"
android:gravity="center">
<android.support.design.widget.TextInputLayout
android:id="@+id/lTextEmail"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp" >
<EditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/lEditEmail"
android:hint="@string/hint_email"
android:inputType="textEmailAddress"
android:padding="20dp"/>
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/lTextPassword"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp" >
<EditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/lEditPassword"
android:hint="@string/hint_password"
android:inputType="textPassword"
android:padding="20dp"/>
</android.support.design.widget.TextInputLayout>
<Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/login"
android:layout_marginTop="20dp"
android:background="@color/colorPrimary"
android:textColor="@color/white"
android:id="@+id/btnLogin"/>
<Button
android:id="@+id/btnLinkToRegisterScreen"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginTop="40dip"
android:background="@null"
android:text="@string/btn_link_to_register"
android:textAllCaps="false"
android:textColor="@color/colorPrimary"
android:textSize="15sp" />
</LinearLayout>
8. Create an activity class named LoginActivity.java. In this class
loginProcess() – Method verifies the login details on the server by making the volley http request.
package akraj.snow.app;
import android.app.ProgressDialog;
import android.content.Intent;
import android.os.Bundle;
import android.support.design.widget.TextInputLayout;
import android.support.v7.app.AppCompatActivity;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.Toast;
import com.android.volley.Request;
import com.android.volley.Response;
import com.android.volley.VolleyError;
import com.android.volley.toolbox.StringRequest;
import org.json.JSONException;
import org.json.JSONObject;
import java.util.HashMap;
import java.util.Map;
/**
* Created by Akshay Raj on 6/16/2016.
*/
public class LoginActivity extends AppCompatActivity {
private static final String TAG = LoginActivity.class.getSimpleName();
private static final String URL_LOGIN = "http://192.168.1.100/android_login/login.php";
private Button btnLogin, btnLinkToRegister;
private TextInputLayout inputEmail, inputPassword;
private ProgressDialog pDialog;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_login);
inputEmail = (TextInputLayout) findViewById(R.id.lTextEmail);
inputPassword = (TextInputLayout) findViewById(R.id.lTextPassword);
btnLogin = (Button) findViewById(R.id.btnLogin);
btnLinkToRegister = (Button) findViewById(R.id.btnLinkToRegisterScreen);
// Progress dialog
pDialog = new ProgressDialog(this);
pDialog.setCancelable(false);
// Login button Click Event
btnLogin.setOnClickListener(new View.OnClickListener() {
public void onClick(View view) {
String email = inputEmail.getEditText().getText().toString().trim();
String password = inputPassword.getEditText().getText().toString().trim();
// Check for empty data in the form
if (!email.isEmpty() && !password.isEmpty()) {
// login user
loginProcess(email, password);
} else {
// Prompt user to enter credentials
Toast.makeText(getApplicationContext(), "Please enter the credentials!", Toast.LENGTH_LONG).show();
}
}
});
// Link to Register Screen
btnLinkToRegister.setOnClickListener(new View.OnClickListener() {
public void onClick(View view) {
Intent i = new Intent(getApplicationContext(), RegisterActivity.class);
startActivity(i);
finish();
}
});
}
private void loginProcess(final String email, final String password) {
// Tag used to cancel the request
String tag_string_req = "req_login";
pDialog.setMessage("Logging in ...");
showDialog();
StringRequest strReq = new StringRequest(Request.Method.POST,
URL_LOGIN, new Response.Listener<String>() {
@Override
public void onResponse(String response) {
Log.d(TAG, "Login Response: " + response.toString());
hideDialog();
try {
JSONObject jObj = new JSONObject(response);
boolean error = jObj.getBoolean("error");
// Check for error node in json
if (!error) {
// user successfully logged in
JSONObject user = jObj.getJSONObject("user");
String name = user.getString("name");
String email = user.getString("email");
// Launch main activity
Intent intent = new Intent(LoginActivity.this, MainActivity.class);
intent.putExtra("name", name);
intent.putExtra("email", email);
startActivity(intent);
finish();
} else {
// Error in login. Get the error message
String errorMsg = jObj.getString("message");
Toast.makeText(getApplicationContext(), errorMsg, Toast.LENGTH_LONG).show();
}
} catch (JSONException e) {
// JSON error
e.printStackTrace();
Toast.makeText(getApplicationContext(), "Json error: " + e.getMessage(), Toast.LENGTH_LONG).show();
}
}
}, new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
Log.e(TAG, "Login Error: " + error.getMessage());
Toast.makeText(getApplicationContext(), error.getMessage(), Toast.LENGTH_LONG).show();
hideDialog();
}
}) {
@Override
protected Map<String, String> getParams() {
// Posting parameters to login url
Map<String, String> params = new HashMap<String, String>();
params.put("email", email);
params.put("password", password);
return params;
}
};
// Adding request to request queue
MyApplication.getInstance().addToRequestQueue(strReq, tag_string_req);
}
private void showDialog() {
if (!pDialog.isShowing())
pDialog.show();
}
private void hideDialog() {
if (pDialog.isShowing())
pDialog.dismiss();
}
}
4.2 Adding the Registration Screen
9. Create an xml layout named activity_register.xml under res ⇒ layout.
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:padding="10dp"
android:gravity="center">
<android.support.design.widget.TextInputLayout
android:id="@+id/rTextName"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp" >
<EditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/rName"
android:hint="@string/hint_name"
android:padding="20dp"/>
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/rTextEmail"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp" >
<EditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/rEditEmail"
android:hint="@string/hint_email"
android:inputType="textEmailAddress"
android:padding="20dp"/>
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/rTextPassword"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp" >
<EditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/rEditPassword"
android:hint="@string/hint_password"
android:inputType="textPassword"
android:padding="20dp"/>
</android.support.design.widget.TextInputLayout>
<Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/register"
android:layout_marginTop="20dp"
android:background="@color/colorPrimary"
android:textColor="@color/white"
android:id="@+id/btnRegister"/>
<Button
android:id="@+id/btnLinkToLoginScreen"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="40dip"
android:background="@null"
android:text="@string/btn_link_to_login"
android:textAllCaps="false"
android:textColor="@color/colorPrimary"
android:textSize="15sp" />
</LinearLayout>
10. Create an activity class named RegisterActivity.java.
registerUser() – Will store the user by passing name, email and password to php, mysql server.
package akraj.snow.app;
import android.app.ProgressDialog;
import android.content.Intent;
import android.os.Bundle;
import android.support.design.widget.TextInputLayout;
import android.support.v7.app.AppCompatActivity;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.Toast;
import com.android.volley.Request;
import com.android.volley.Response;
import com.android.volley.VolleyError;
import com.android.volley.toolbox.StringRequest;
import org.json.JSONException;
import org.json.JSONObject;
import java.util.HashMap;
import java.util.Map;
/**
* Created by Akshay Raj on 6/16/2016.
*/
public class RegisterActivity extends AppCompatActivity {
private static final String TAG = RegisterActivity.class.getSimpleName();
private static final String URL_REGISTER = "http://192.168.1.100/android_login/register.php";
private Button btnRegister, btnLinkToLogin;
private TextInputLayout inputName, inputEmail, inputPassword;
private ProgressDialog pDialog;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_register);
inputName = (TextInputLayout) findViewById(R.id.rTextName);
inputEmail = (TextInputLayout) findViewById(R.id.rTextEmail);
inputPassword = (TextInputLayout) findViewById(R.id.rTextPassword);
btnRegister = (Button) findViewById(R.id.btnRegister);
btnLinkToLogin = (Button) findViewById(R.id.btnLinkToLoginScreen);
// Progress dialog
pDialog = new ProgressDialog(this);
pDialog.setCancelable(false);
// Login button Click Event
btnRegister.setOnClickListener(new View.OnClickListener() {
public void onClick(View view) {
String name = inputName.getEditText().getText().toString().trim();
String email = inputEmail.getEditText().getText().toString().trim();
String password = inputPassword.getEditText().getText().toString().trim();
// Check for empty data in the form
if (!name.isEmpty() && !email.isEmpty() && !password.isEmpty()) {
registerUser(name, email, password);
} else {
Toast.makeText(getApplicationContext(), "Please enter your details!", Toast.LENGTH_LONG).show();
}
}
});
// Link to Register Screen
btnLinkToLogin.setOnClickListener(new View.OnClickListener() {
public void onClick(View view) {
Intent i = new Intent(RegisterActivity.this, LoginActivity.class);
startActivity(i);
finish();
}
});
}
private void registerUser(final String name, final String email, final String password) {
// Tag used to cancel the request
String tag_string_req = "req_register";
pDialog.setMessage("Registering ...");
showDialog();
StringRequest strReq = new StringRequest(Request.Method.POST,
URL_REGISTER, new Response.Listener<String>() {
@Override
public void onResponse(String response) {
Log.d(TAG, "Register Response: " + response.toString());
hideDialog();
try {
JSONObject jObj = new JSONObject(response);
boolean error = jObj.getBoolean("error");
if (!error) {
// User successfully stored in MySQL
Toast.makeText(getApplicationContext(),
"User successfully registered. Try login now!", Toast.LENGTH_LONG).show();
// Launch login activity
Intent intent = new Intent(RegisterActivity.this, LoginActivity.class);
startActivity(intent);
finish();
} else {
// Error occurred in registration. Get the error
// message
String errorMsg = jObj.getString("error_msg");
Toast.makeText(getApplicationContext(),errorMsg, Toast.LENGTH_LONG).show();
}
} catch (JSONException e) {
e.printStackTrace();
}
}
}, new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
Log.e(TAG, "Registration Error: " + error.getMessage());
Toast.makeText(getApplicationContext(), error.getMessage(), Toast.LENGTH_LONG).show();
hideDialog();
}
}) {
@Override
protected Map<String, String> getParams() {
// Posting params to register url
Map<String, String> params = new HashMap<String, String>();
params.put("name", name);
params.put("email", email);
params.put("password", password);
return params;
}
};
// Adding request to request queue
MyApplication.getInstance().addToRequestQueue(strReq, tag_string_req);
}
private void showDialog() {
if (!pDialog.isShowing())
pDialog.show();
}
private void hideDialog() {
if (pDialog.isShowing())
pDialog.dismiss();
}
}
4.3 Adding the Home Screen
Until now we are done with both login and registration screen. Now we’ll add the final screen to show the logged in user information. This information will be fetched from SQLite database once user is logged in.
11. Create an xml file named activity_main.xml under res ⇒ layout and add below code.
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_centerInParent="true"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:gravity="center"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/welcome"
android:textSize="20sp" />
<TextView
android:id="@+id/name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="10dp"
android:textSize="24sp" />
<TextView
android:id="@+id/email"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="13sp" />
</LinearLayout>
12. Open the MainActivity.java and do below changes. Here we are just fetching the logged user information from Intent and displaying it on the screen.
package akraj.snow.app;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.widget.TextView;
/**
* Created by Akshay Raj on 6/16/2016.
*/
public class MainActivity extends AppCompatActivity {
private TextView txtName, txtEmail;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
txtName = (TextView) findViewById(R.id.name);
txtEmail = (TextView) findViewById(R.id.email);
// Fetching user details from LoginActivity
Bundle bundle = getIntent().getExtras();
String name = bundle.getString("name");
String email = bundle.getString("email");
// Displaying the user details on the screen
txtName.setText(name);
txtEmail.setText(email);
}
}
5. Testing the App
For a beginner it will be always difficult to run this project for the first time. But don’t worry, the following steps will helps you testing this app. (The ip address looks like 192.168.1.100)
⇒ Make sure that both devices (the device running the PHP project and the android device) are on the same wifi network.
⇒ Give correct username , password and database name of MySQL in config.php
⇒ Replace the URL ip address of URL_LOGIN and URL_REGISTER with your machine ip address. You can get the ip address by running ipconfig in cmd
Below are the final outputs of this project.
Thank you!
Very good! good explanation!
welcome 🙂
please help me, i have problem my project from your code.
this my problem :
08-29 11:30:30.867 19451-19451/com.dani.skripsi.myapplication E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.dani.skripsi.myapplication, PID: 19451
java.lang.NullPointerException: Attempt to invoke virtual method ‘void com.dani.skripsi.myapplication.MyApplication.addToRequestQueue(com.android.volley.Request, java.lang.String)’ on a null object reference
at com.dani.skripsi.myapplication.RegisterActivity.registerUser(RegisterActivity.java:141)
at com.dani.skripsi.myapplication.RegisterActivity.access$300(RegisterActivity.java:24)
at com.dani.skripsi.myapplication.RegisterActivity$1.onClick(RegisterActivity.java:57)
at android.view.View.performClick(View.java:4756)
at android.view.View$PerformClick.run(View.java:19761)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5264)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:900)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:695)
com.dani.skripsi.myapplication.RegisterActivity.registerUser(RegisterActivity.java:141)
click on bold text in your error RegisterActivity.java:141 and send your code line
hi thanks for sharing . i run this project in real server but i got some errors and i know that errors happened for addresses . so here we go :
this my login and register path :
private static final String URL_LOGIN = “http://memaraneha.ir/Erfan/android_login/login.php”;
private static final String URL_LOGIN = “http://memaraneha.ir/Erfan/android_login/register.php”;
and this is my config info (i am sure about correct and existing These) :
$username = “yashilgo_eri”;
$password = “erfan1373”;
$host = “memaraneha.ir”;
$dbname = “yashilgo_erfan”;
so what is wrong ?
Change URL_LOGIN to URL_REGISTER in 2nd line. Also check url in login and registration method
nothing is getting entered in wamp server database and whn iregister a black circle comes at the bottom
E/Volley: [6156] BasicNetwork.performRequest: Unexpected response code 403 for http://192.168.1.3/android_login/login.php
E/LoginActivity: Login Error: null
E/ViewRootImpl: sendUserActionEvent() mView == null
Open your url in browser and check error
it shows Android Learning
Check in mobile browser
U dont have permission to access /adroid_login/login.php on this server
Apache/2.4.18(Win64)PHP/5.6.19 Server at 192.168.1.3 Port 80
This is the message
Check your wamp server is online.
http://cdn.windows7themes.net/pics/wampserver-start-all-services-put-online.jpg
yes it is online i restarted all services and also did as per ur image
Check your wamp server settings and ip address.
Ip address is correct andwhatwamp settings should i do??
where is the PHP code to validate the password ??? I can Login using any password 😀
Sorry.. It’s my mistake. I updated my code. Thank you for showing my mistake.
where is the password checking code in php file of login ??? …… it is working with wrong password also
ohh i found your password code but code is not working after adding password related code please check 🙂
oh it was my mistake …thanks it is working and nice tutorial i tried one more tutorial which was not working for me bcoz of result_get() method which is use in sqlnd but this tuto is working 🙂
Thank you raman 🙂
How would you scale the backend and add frontend views for user groups (a user can be part of multiple groups (checkboxes ? maybe)
and user profiles (search and view)
and add Push notification layer when a new user joins for other to see his profile and contact him if needed
registration works but when I try to login it says Json error: Value <br of type java.lang.String can not be converted to JSONObject
i updated my code.
akshay ji aapko codeing main kuch prb hai when i creat that code the application was unfortunatly has stoped error is show
ok… i’ll check and update my code.
i updated my code.
Can you tell me where have you made a change because I can’t find update that you made so please point out where should i need some changes ASAP.
line 32 in login.php
if (password_verify($_POST['password'], $row['encrypted_password'])) {
Thank you for your instant replay much appreciated man. Keep doing what you are doing. Thanks again
please hope this works fine
hello akshay bro can i got your contact no. plz my contact no. is 9229788000
Hello thank but I have a problem.
Im using azure to my host and my dtaba base, when I put android_login_api/register.php or android_login_api/login.php I have the message that say error_msg: “Required parameters email or password is missing!” so I put like android_login_api/[email protected] but it doesn´t work.
Please helpe!!! what can I do?
Thanks
your database not receiving any values.
Thank you but I have a problème:
java.net.ConnectException:failed to
connect to /192.168.1.100(port 80)after
5000ms:isConnected failed:
EHOSTUNREACH (No route to host)
Please helpe me !! what can I do?
Thanks.
change url with your localhost server ip address.
Thanks, but I have another probléme.
He wrote me blank message.
Thanks
send me screenshot of error to my facebook (https://www.facebook.com/akrajilwar)
bro i need java and php code for login and registration with database and validation
go to this link Android Login Registration System with PHP, MySQL and Sqlite
ibra first check u r systems ip address than that ip address place on u r app
hi akhsay im also gettin a null pointer on
MyApplication.getInstance().addToRequestQueue(strReq, tag_string_req);
im compilin on sdk 25.
i also notice on volley im gettin error on AndroidHttpClient.
is this due to its depreciation?
ty in adv
add MyApplication to your manifest:
It works very nice ,but how to prevent showing login page when user open the app next time..It is show login page every time I open the app.
i’m posting a new tutorial very soon about store login data in session, reset password and verify email.
I tried your code. it throws error in import ‘android.support.design.widget.TextInputLayout’. please help me to fix it.
Use Design Support Library with this Gradle dependencies:-
compile 'com.android.support:design:25.3.0'
Hai, am a beginner and i don’t know what i wanna do with the “JSON Responses”????
1: if i want to store it some file like .php or wot?
please get me out with this!
Hi, AKSHAY RAJ do you have PHP coding for update password?
Yes, check out this post Android Login Registration System with PHP, MySQL and Sqlite
Sir I am a begineer and i want to understand how will be I able to integrate my android code with my php or server programming on same IDE platform using localhhost. Can u explain in brief.
check full source code Android-Login-And-Registration
Bonjour,
Super boulot, probleme après essaie enregistrement rien ne se passe. J’ai enregistring qui s’affiche avec le screen qui tourne mais pas d’enregistrement dans base de donnée.
Merci de votre aide
please i am getting unresolved method getEditText
Same!
Send your query to our facebook page or whatsapp support.
Impressive and very well explained
Hello
I get a blank message after i click on register. Can you help me please
can you show me android log when you click register button? You can contact me on facebook or Whatsapp.
thanks, for this tuto i use xampp server so i should set these files in htdocs forlder.
yes.
Very good explanation.
I copied all files to my project, but I’m unable to assign MyApplication as the startscreen. It refuses in the manifest.
What am I doing wrong?
All compiled with success.
Hello Marc, check error on Log Monitor
Wrong place 🙂
Ok ?