国产 无码 综合区,色欲AV无码国产永久播放,无码天堂亚洲国产AV,国产日韩欧美女同一区二区

Android安卓實(shí)戰(zhàn)項(xiàng)目---登陸注冊(cè)頁面(源碼在文末)

這篇具有很好參考價(jià)值的文章主要介紹了Android安卓實(shí)戰(zhàn)項(xiàng)目---登陸注冊(cè)頁面(源碼在文末)。希望對(duì)大家有所幫助。如果存在錯(cuò)誤或未考慮完全的地方,請(qǐng)大家不吝賜教,您也可以點(diǎn)擊"舉報(bào)違法"按鈕提交疑問。

Android安卓實(shí)戰(zhàn)項(xiàng)目---登陸注冊(cè)頁面(源碼在文末??????)

一.項(xiàng)目運(yùn)行介紹

效果圖:

android登錄注冊(cè)完整代碼,Android開源項(xiàng)目,android,android studio,java

android登錄注冊(cè)完整代碼,Android開源項(xiàng)目,android,android studio,java

二.具體實(shí)現(xiàn)

LoginActivity.java
LoginActivity.java
package com.example.login;
?
import android.content.Intent;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.text.TextUtils;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.CompoundButton;
import android.widget.EditText;
import android.widget.Toast;
?
import androidx.appcompat.app.AppCompatActivity;
?
import com.example.angel.GuideActivity;
import com.example.angel.R;
?
import org.jetbrains.annotations.Nullable;
?
public class LoginActivity extends AppCompatActivity {
?
 ?  private static final String TAG = "tag";
 ?  public static final int REQUEST_CODE_REGISTER = 1;
 ?  private Button btnLogin;
 ?  private EditText etAccount,etPassword;
 ?  private CheckBox cbRemember,cbAutoLogin;
?
 ?  private String userName = "fxjzzyo";
 ?  private String pass = "123";
?
 ?  @Override
 ?  protected void onCreate(Bundle savedInstanceState) {
 ? ? ?  super.onCreate(savedInstanceState);
 ? ? ?  setContentView(R.layout.activity_login);
 ? ? ?  getSupportActionBar().setTitle("登錄");
?
 ? ? ?  initView();
 ? ? ?  initData();
?
 ? ? ?  btnLogin.setOnClickListener(new View.OnClickListener() {
 ? ? ? ? ?  @Override
 ? ? ? ? ?  public void onClick(View v) {
 ? ? ? ? ? ? ?  String account = etAccount.getText().toString();
 ? ? ? ? ? ? ?  String password = etPassword.getText().toString();
?
 ? ? ? ? ? ? ?  Log.d(TAG, "onClick: -------------" + account);
 ? ? ? ? ? ? ?  Log.d(TAG, "password: -------------" + password);
 ? ? ? ? ? ? ?  if (TextUtils.isEmpty(userName)) {
 ? ? ? ? ? ? ? ? ?  Toast.makeText(LoginActivity.this, "還沒有注冊(cè)賬號(hào)!", Toast.LENGTH_LONG).show();
 ? ? ? ? ? ? ? ? ?  return;
 ? ? ? ? ? ? ?  }
?
 ? ? ? ? ? ? ?  if (TextUtils.equals(account, userName)) {
 ? ? ? ? ? ? ? ? ?  if (TextUtils.equals(password, pass)) {
?
 ? ? ? ? ? ? ? ? ? ? ?  Toast.makeText(LoginActivity.this, "恭喜你,登錄成功!", Toast.LENGTH_LONG).show();
 ? ? ? ? ? ? ? ? ? ? ?  if (cbRemember.isChecked()) {
 ? ? ? ? ? ? ? ? ? ? ? ? ?  SharedPreferences spf = getSharedPreferences("spfRecord", MODE_PRIVATE);
 ? ? ? ? ? ? ? ? ? ? ? ? ?  SharedPreferences.Editor edit = spf.edit();
 ? ? ? ? ? ? ? ? ? ? ? ? ?  edit.putString("account", account);
 ? ? ? ? ? ? ? ? ? ? ? ? ?  edit.putString("password", password);
 ? ? ? ? ? ? ? ? ? ? ? ? ?  edit.putBoolean("isRemember", true);
 ? ? ? ? ? ? ? ? ? ? ? ? ?  if (cbAutoLogin.isChecked()) {
 ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?  edit.putBoolean("isLogin", true);
 ? ? ? ? ? ? ? ? ? ? ? ? ?  }else {
 ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?  edit.putBoolean("isLogin", false);
 ? ? ? ? ? ? ? ? ? ? ? ? ?  }
 ? ? ? ? ? ? ? ? ? ? ? ? ?  edit.apply();
?
 ? ? ? ? ? ? ? ? ? ? ?  }else {
 ? ? ? ? ? ? ? ? ? ? ? ? ?  SharedPreferences spf = getSharedPreferences("spfRecord", MODE_PRIVATE);
 ? ? ? ? ? ? ? ? ? ? ? ? ?  SharedPreferences.Editor edit = spf.edit();
 ? ? ? ? ? ? ? ? ? ? ? ? ?  edit.putBoolean("isRemember", false);
 ? ? ? ? ? ? ? ? ? ? ? ? ?  edit.apply();
 ? ? ? ? ? ? ? ? ? ? ?  }
?
 ? ? ? ? ? ? ? ? ? ? ?  Intent intent = new Intent(LoginActivity.this, GuideActivity.class);
 ? ? ? ? ? ? ? ? ? ? ?  intent.putExtra("account", account);
 ? ? ? ? ? ? ? ? ? ? ?  startActivity(intent);
 ? ? ? ? ? ? ? ? ? ? ?  LoginActivity.this.finish();
?
 ? ? ? ? ? ? ? ? ?  } else {
 ? ? ? ? ? ? ? ? ? ? ?  Toast.makeText(LoginActivity.this, "密碼錯(cuò)誤!", Toast.LENGTH_LONG).show();
 ? ? ? ? ? ? ? ? ?  }
 ? ? ? ? ? ? ?  } else {
 ? ? ? ? ? ? ? ? ?  Toast.makeText(LoginActivity.this, "用戶名錯(cuò)誤!", Toast.LENGTH_LONG).show();
 ? ? ? ? ? ? ?  }
?
 ? ? ? ? ?  }
 ? ? ?  });
?
 ? ? ?  cbAutoLogin.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
 ? ? ? ? ?  @Override
 ? ? ? ? ?  public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
 ? ? ? ? ? ? ?  if (isChecked) {
 ? ? ? ? ? ? ? ? ?  cbRemember.setChecked(true);
 ? ? ? ? ? ? ?  }
 ? ? ? ? ?  }
 ? ? ?  });
?
 ? ? ?  cbRemember.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
 ? ? ? ? ?  @Override
 ? ? ? ? ?  public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
 ? ? ? ? ? ? ?  if (!isChecked) {
 ? ? ? ? ? ? ? ? ?  cbAutoLogin.setChecked(false);
 ? ? ? ? ? ? ?  }
 ? ? ? ? ?  }
 ? ? ?  });
?
 ?  }
?
?
?
 ?  private void initView() {
 ? ? ?  btnLogin = findViewById(R.id.btn_login);
 ? ? ?  etAccount = findViewById(R.id.et_account);
 ? ? ?  etPassword = findViewById(R.id.et_password);
 ? ? ?  cbRemember = findViewById(R.id.cb_remember);
 ? ? ?  cbAutoLogin = findViewById(R.id.cb_auto_login);
?
 ?  }
?
 ?  private void initData() {
 ? ? ?  SharedPreferences spf = getSharedPreferences("spfRecord", MODE_PRIVATE);
 ? ? ?  boolean isRemember = spf.getBoolean("isRemember", false);
 ? ? ?  boolean isLogin = spf.getBoolean("isLogin", false);
 ? ? ?  String account = spf.getString("account", "");
 ? ? ?  String password = spf.getString("password", "");
?
?
 ? ? ?  if (isLogin) {
 ? ? ? ? ?  Intent intent = new Intent(LoginActivity.this, GuideActivity.class);
 ? ? ? ? ?  intent.putExtra("account", account);
 ? ? ? ? ?  startActivity(intent);
 ? ? ? ? ?  LoginActivity.this.finish();
 ? ? ?  }
?
?
 ? ? ?  userName = account;
 ? ? ?  pass = password;
?
 ? ? ?  if (isRemember) {
 ? ? ? ? ?  etAccount.setText(account);
 ? ? ? ? ?  etPassword.setText(password);
 ? ? ? ? ?  cbRemember.setChecked(true);
 ? ? ?  }
?
?
 ?  }
?
 ?  public void toRegister(View view) {
 ? ? ?  Intent intent = new Intent(this, RegisterActivity.class);
?
 ? ? ?  startActivityForResult(intent, REQUEST_CODE_REGISTER);
 ?  }
?
 ?  @Override
 ?  protected void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {
 ? ? ?  super.onActivityResult(requestCode, resultCode, data);
 ? ? ?  if (requestCode == REQUEST_CODE_REGISTER && resultCode == RegisterActivity.RESULT_CODE_REGISTER && data != null) {
 ? ? ? ? ?  Bundle extras = data.getExtras();
?
 ? ? ? ? ?  String account = extras.getString("account", "");
 ? ? ? ? ?  String password = extras.getString("password", "");
?
 ? ? ? ? ?  etAccount.setText(account);
 ? ? ? ? ?  etPassword.setText(password);
?
 ? ? ? ? ?  userName = account;
 ? ? ? ? ?  pass = password;
 ? ? ?  }
 ?  }
}

這段代碼是一個(gè)簡(jiǎn)單的Android應(yīng)用中的登錄功能代碼,下面逐行解釋其功能和作用:

  1. 導(dǎo)入相關(guān)的類和包:

package com.example.userprofile23_1;
?
import android.content.Intent;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.text.TextUtils;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.CompoundButton;
import android.widget.EditText;
import android.widget.Toast;
?
import androidx.annotation.Nullable;
import androidx.appcompat.app.AppCompatActivity;

這些導(dǎo)入語句引入了用于構(gòu)建Android應(yīng)用界面、處理用戶交互和數(shù)據(jù)存儲(chǔ)的必要類和包。

  1. 定義一個(gè)名為LoginActivity的類,它繼承自AppCompatActivity,表示這是一個(gè)用于處理界面的活動(dòng)(Activity)。

public class LoginActivity extends AppCompatActivity {
  1. 聲明類中需要用到的一些變量和常量:

private static final String TAG = "tag";
public static final int REQUEST_CODE_REGISTER = 1;
private Button btnLogin;
private EditText etAccount, etPassword;
private CheckBox cbRemember, cbAutoLogin;
private String userName = "fxjzzyo";
private String pass = "123";
  • TAG:用于在日志中標(biāo)記的標(biāo)簽。

  • REQUEST_CODE_REGISTER:用于在startActivityForResult中標(biāo)識(shí)注冊(cè)活動(dòng)的請(qǐng)求代碼。

  • btnLogin:登錄按鈕。

  • etAccountetPassword:輸入用戶名和密碼的文本框。

  • cbRemember、cbAutoLogin:復(fù)選框,分別表示是否記住密碼和是否自動(dòng)登錄。

  • userName、pass:默認(rèn)的用戶名和密碼。

  1. onCreate方法中初始化界面元素和處理點(diǎn)擊事件:

@Override
protected void onCreate(Bundle savedInstanceState) {
 ? ?super.onCreate(savedInstanceState);
 ? ?setContentView(R.layout.activity_login);
 ? ?getSupportActionBar().setTitle("登錄");
?
 ? ?initView();
 ? ?initData();
?
 ? ?// ... 省略了部分代碼
?
 ? ?btnLogin.setOnClickListener(new View.OnClickListener() {
 ? ? ? ?@Override
 ? ? ? ?public void onClick(View v) {
 ? ? ? ? ? ?// ... 處理登錄邏輯
 ? ? ?  }
 ?  });
?
 ? ?cbAutoLogin.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
 ? ? ? ?@Override
 ? ? ? ?public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
 ? ? ? ? ? ?// ... 處理自動(dòng)登錄復(fù)選框狀態(tài)改變的邏輯
 ? ? ?  }
 ?  });
?
 ? ?cbRemember.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
 ? ? ? ?@Override
 ? ? ? ?public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
 ? ? ? ? ? ?// ... 處理記住密碼復(fù)選框狀態(tài)改變的邏輯
 ? ? ?  }
 ?  });
}
  1. initView() 方法用于初始化界面元素,將 XML 布局中的控件與變量關(guān)聯(lián)起來:

private void initView() {
 ? ?btnLogin = findViewById(R.id.btn_login);
 ? ?etAccount = findViewById(R.id.et_account);
 ? ?etPassword = findViewById(R.id.et_password);
 ? ?cbRemember = findViewById(R.id.cb_remember);
 ? ?cbAutoLogin = findViewById(R.id.cb_auto_login);
}
  1. initData() 方法用于初始化數(shù)據(jù),根據(jù)用戶的記住密碼和自動(dòng)登錄的設(shè)置,更新界面元素和變量的狀態(tài):

private void initData() {
 ? ?SharedPreferences spf = getSharedPreferences("spfRecord", MODE_PRIVATE);
 ? ?boolean isRemember = spf.getBoolean("isRemember", false);
 ? ?boolean isLogin = spf.getBoolean("isLogin", false);
 ? ?String account = spf.getString("account", "");
 ? ?String password = spf.getString("password", "");
?
 ? ?// ... 處理自動(dòng)登錄邏輯
?
 ? ?userName = account;
 ? ?pass = password;
?
 ? ?if (isRemember) {
 ? ? ? ?etAccount.setText(account);
 ? ? ? ?etPassword.setText(password);
 ? ? ? ?cbRemember.setChecked(true);
 ?  }
}
  1. btnLogin 按鈕的點(diǎn)擊事件處理,用于驗(yàn)證用戶輸入的用戶名和密碼是否匹配,并根據(jù)復(fù)選框的狀態(tài)更新數(shù)據(jù)到SharedPreferences中:

btnLogin.setOnClickListener(new View.OnClickListener() {
 ? ?@Override
 ? ?public void onClick(View v) {
 ? ? ? ?// 獲取用戶輸入的用戶名和密碼
 ? ? ? ?String account = etAccount.getText().toString();
 ? ? ? ?String password = etPassword.getText().toString();
?
 ? ? ? ?if (TextUtils.isEmpty(userName)) {
 ? ? ? ? ? ?// 用戶未注冊(cè)
 ? ? ? ? ? ?Toast.makeText(LoginActivity.this, "還沒有注冊(cè)賬號(hào)!", Toast.LENGTH_LONG).show();
 ? ? ? ? ? ?return;
 ? ? ?  }
?
 ? ? ? ?if (TextUtils.equals(account, userName)) {
 ? ? ? ? ? ?if (TextUtils.equals(password, pass)) {
 ? ? ? ? ? ? ? ?// 登錄成功
 ? ? ? ? ? ? ? ?// ... 處理登錄成功邏輯
 ? ? ? ? ?  } else {
 ? ? ? ? ? ? ? ?// 密碼錯(cuò)誤
 ? ? ? ? ? ? ? ?Toast.makeText(LoginActivity.this, "密碼錯(cuò)誤!", Toast.LENGTH_LONG).show();
 ? ? ? ? ?  }
 ? ? ?  } else {
 ? ? ? ? ? ?// 用戶名錯(cuò)誤
 ? ? ? ? ? ?Toast.makeText(LoginActivity.this, "用戶名錯(cuò)誤!", Toast.LENGTH_LONG).show();
 ? ? ?  }
 ?  }
});
  1. cbAutoLogincbRemember 復(fù)選框狀態(tài)改變的監(jiān)聽器,確保自動(dòng)登錄時(shí)同時(shí)記住密碼,取消記住密碼時(shí)取消自動(dòng)登錄:

cbAutoLogin.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
 ? ?@Override
 ? ?public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
 ? ? ? ?if (isChecked) {
 ? ? ? ? ? ?cbRemember.setChecked(true);
 ? ? ?  }
 ?  }
});
?
cbRemember.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
 ? ?@Override
 ? ?public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
 ? ? ? ?if (!isChecked) {
 ? ? ? ? ? ?cbAutoLogin.setChecked(false);
 ? ? ?  }
 ?  }
});
  1. toRegister(View view) 方法處理前往注冊(cè)界面的按鈕點(diǎn)擊事件,啟動(dòng)RegisterActivity來進(jìn)行用戶注冊(cè):

public void toRegister(View view) {
 ? ?Intent intent = new Intent(this, RegisterActivity.class);
 ? ?startActivityForResult(intent, REQUEST_CODE_REGISTER);
}
  1. onActivityResult(int requestCode, int resultCode, @Nullable Intent data) 方法處理從注冊(cè)界面返回的結(jié)果,獲取注冊(cè)的用戶名和密碼,并更新界面元素和數(shù)據(jù):

@Override
protected void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {
 ? ?super.onActivityResult(requestCode, resultCode, data);
 ? ?if (requestCode == REQUEST_CODE_REGISTER && resultCode == RegisterActivity.RESULT_CODE_REGISTER && data != null) {
 ? ? ? ?Bundle extras = data.getExtras();
 ? ? ? ?String account = extras.getString("account", "");
 ? ? ? ?String password = extras.getString("password", "");
?
 ? ? ? ?etAccount.setText(account);
 ? ? ? ?etPassword.setText(password);
?
 ? ? ? ?userName = account;
 ? ? ? ?pass = password;
 ?  }
}

這段代碼實(shí)現(xiàn)了一個(gè)簡(jiǎn)單的登錄功能,包括記住密碼、自動(dòng)登錄、用戶名和密碼驗(yàn)證等

RegisterActivity.Java
package com.example.login;
?
import android.content.Intent;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.text.TextUtils;
import android.view.View;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.EditText;
import android.widget.Toast;
?
import androidx.appcompat.app.AppCompatActivity;
?
import com.example.angel.R;
?
public class RegisterActivity extends AppCompatActivity implements View.OnClickListener {
?
 ?  public static final int RESULT_CODE_REGISTER = 0;
 ?  private Button btnRegister;
 ?  private EditText etAccount,etPass,etPassConfirm;
 ?  private CheckBox cbAgree;
?
 ?  @Override
 ?  protected void onCreate(Bundle savedInstanceState) {
 ? ? ?  super.onCreate(savedInstanceState);
 ? ? ?  setContentView(R.layout.activity_register);
 ? ? ?  getSupportActionBar().setTitle("注冊(cè)");
?
 ? ? ?  etAccount = findViewById(R.id.et_account);
 ? ? ?  etPass = findViewById(R.id.et_password);
 ? ? ?  etPassConfirm = findViewById(R.id.et_password_confirm);
 ? ? ?  cbAgree = findViewById(R.id.cb_agree);
 ? ? ?  btnRegister = findViewById(R.id.btn_register);
?
 ? ? ?  btnRegister.setOnClickListener(this);
?
 ?  }
?
 ?  @Override
 ?  public void onClick(View v) {
 ? ? ?  String name = etAccount.getText().toString();
 ? ? ?  String pass = etPass.getText().toString();
 ? ? ?  String passConfirm = etPassConfirm.getText().toString();
?
 ? ? ?  if (TextUtils.isEmpty(name)) {
 ? ? ? ? ?  Toast.makeText(RegisterActivity.this, "用戶名不能為空", Toast.LENGTH_LONG).show();
?
 ? ? ? ? ?  return;
 ? ? ?  }
?
 ? ? ?  if (TextUtils.isEmpty(pass)) {
 ? ? ? ? ?  Toast.makeText(RegisterActivity.this, "密碼不能為空", Toast.LENGTH_LONG).show();
 ? ? ? ? ?  return;
 ? ? ?  }
?
 ? ? ?  if (!TextUtils.equals(pass,passConfirm)) {
 ? ? ? ? ?  Toast.makeText(RegisterActivity.this, "密碼不一致", Toast.LENGTH_LONG).show();
 ? ? ? ? ?  return;
 ? ? ?  }
?
 ? ? ?  if (!cbAgree.isChecked()) {
 ? ? ? ? ?  Toast.makeText(RegisterActivity.this, "請(qǐng)同意用戶協(xié)議", Toast.LENGTH_LONG).show();
 ? ? ? ? ?  return;
 ? ? ?  }
?
 ? ? ?  // 存儲(chǔ)注冊(cè)的用戶名 密碼
 ? ? ?  SharedPreferences spf = getSharedPreferences("spfRecord", MODE_PRIVATE);
 ? ? ?  SharedPreferences.Editor edit = spf.edit();
 ? ? ?  edit.putString("account", name);
 ? ? ?  edit.putString("password", pass);
 ? ? ?  edit.apply();
?
 ? ? ?  // 數(shù)據(jù)回傳
 ? ? ?  Intent intent = new Intent();
 ? ? ?  Bundle bundle = new Bundle();
 ? ? ?  bundle.putString("account",name);
 ? ? ?  bundle.putString("password",pass);
 ? ? ?  intent.putExtras(bundle);
 ? ? ?  setResult(RESULT_CODE_REGISTER,intent);
?
?
 ? ? ?  Toast.makeText(RegisterActivity.this, "注冊(cè)成功!", Toast.LENGTH_LONG).show();
 ? ? ?  this.finish();
 ?  }
}

這段代碼是一個(gè)用于注冊(cè)用戶的 Android 應(yīng)用程序的一部分。我會(huì)逐行解釋每個(gè)部分的作用和功能。

  1. 導(dǎo)入所需的類和包:

package com.example.userprofile23_1;
?
import android.content.Intent;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.text.TextUtils;
import android.view.View;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.EditText;
import android.widget.Toast;
?
import androidx.appcompat.app.AppCompatActivity;

在這個(gè)部分,代碼導(dǎo)入了所需的 Android 類和包,以便后續(xù)使用。這些包括處理界面元素(如 EditText、Button、CheckBox)、處理數(shù)據(jù)存儲(chǔ)(SharedPreferences)以及處理界面操作(AppCompatActivity)等。

  1. 創(chuàng)建 RegisterActivity 類:

public class RegisterActivity extends AppCompatActivity implements View.OnClickListener {

這段代碼定義了一個(gè)名為 RegisterActivity 的類,該類繼承自 AppCompatActivity 類,并實(shí)現(xiàn)了 View.OnClickListener 接口。這意味著該類可以作為一個(gè)活動(dòng)(Activity)來運(yùn)行,并且可以響應(yīng)視圖上的點(diǎn)擊事件。

  1. 聲明變量和常量:

public static final int RESULT_CODE_REGISTER = 0;
private Button btnRegister;
private EditText etAccount, etPass, etPassConfirm;
private CheckBox cbAgree;

這部分聲明了一些變量和常量,用于處理注冊(cè)界面中的各個(gè)組件。其中:

  • RESULT_CODE_REGISTER 是一個(gè)常量,用于表示注冊(cè)操作的結(jié)果代碼。

  • btnRegister 是一個(gè) Button 對(duì)象,代表注冊(cè)按鈕。

  • etAccount、etPass、etPassConfirm 分別是三個(gè) EditText 對(duì)象,分別用于輸入用戶名、密碼和確認(rèn)密碼。

  • cbAgree 是一個(gè) CheckBox 對(duì)象,用于表示用戶是否同意用戶協(xié)議。

  1. 在 onCreate 方法中進(jìn)行初始化:

@Override
protected void onCreate(Bundle savedInstanceState) {
 ? ?super.onCreate(savedInstanceState);
 ? ?setContentView(R.layout.activity_register);
 ? ?getSupportActionBar().setTitle("注冊(cè)");
?
 ? ?etAccount = findViewById(R.id.et_account);
 ? ?etPass = findViewById(R.id.et_password);
 ? ?etPassConfirm = findViewById(R.id.et_password_confirm);
 ? ?cbAgree = findViewById(R.id.cb_agree);
 ? ?btnRegister = findViewById(R.id.btn_register);
?
 ? ?btnRegister.setOnClickListener(this);
}

在這部分代碼中,onCreate 方法是 Android 活動(dòng)的一個(gè)生命周期方法,用于在活動(dòng)創(chuàng)建時(shí)進(jìn)行初始化操作。具體的初始化步驟包括:

  • 設(shè)置活動(dòng)的布局為 "activity_register",即注冊(cè)界面的布局。

  • 設(shè)置活動(dòng)的標(biāo)題為 "注冊(cè)"。

  • 獲取用戶名、密碼、確認(rèn)密碼和同意協(xié)議的 EditText 和 CheckBox 對(duì)象。

  • 獲取注冊(cè)按鈕,并設(shè)置點(diǎn)擊監(jiān)聽器為當(dāng)前活動(dòng)(實(shí)現(xiàn)了 View.OnClickListener 接口)。

  1. 實(shí)現(xiàn) onClick 方法:

@Override
public void onClick(View v) {
 ? ?String name = etAccount.getText().toString();
 ? ?String pass = etPass.getText().toString();
 ? ?String passConfirm = etPassConfirm.getText().toString();
?
 ? ?if (TextUtils.isEmpty(name)) {
 ? ? ? ?Toast.makeText(RegisterActivity.this, "用戶名不能為空", Toast.LENGTH_LONG).show();
 ? ? ? ?return;
 ?  }
?
 ? ?if (TextUtils.isEmpty(pass)) {
 ? ? ? ?Toast.makeText(RegisterActivity.this, "密碼不能為空", Toast.LENGTH_LONG).show();
 ? ? ? ?return;
 ?  }
?
 ? ?if (!TextUtils.equals(pass, passConfirm)) {
 ? ? ? ?Toast.makeText(RegisterActivity.this, "密碼不一致", Toast.LENGTH_LONG).show();
 ? ? ? ?return;
 ?  }
?
 ? ?if (!cbAgree.isChecked()) {
 ? ? ? ?Toast.makeText(RegisterActivity.this, "請(qǐng)同意用戶協(xié)議", Toast.LENGTH_LONG).show();
 ? ? ? ?return;
 ?  }
?
 ? ?SharedPreferences spf = getSharedPreferences("spfRecord", MODE_PRIVATE);
 ? ?SharedPreferences.Editor edit = spf.edit();
 ? ?edit.putString("account", name);
 ? ?edit.putString("password", pass);
 ? ?edit.apply();
?
 ? ?Intent intent = new Intent();
 ? ?Bundle bundle = new Bundle();
 ? ?bundle.putString("account", name);
 ? ?bundle.putString("password", pass);
 ? ?intent.putExtras(bundle);
 ? ?setResult(RESULT_CODE_REGISTER, intent);
?
 ? ?Toast.makeText(RegisterActivity.this, "注冊(cè)成功!", Toast.LENGTH_LONG).show();
 ? ?this.finish();
}

這部分代碼實(shí)現(xiàn)了在按鈕點(diǎn)擊事件中執(zhí)行的操作,主要包括:

  • 獲取用戶名、密碼和確認(rèn)密碼的字符串。

  • 檢查用戶名、密碼是否為空,以及確認(rèn)密碼是否與密碼一致,以及是否勾選了用戶協(xié)議的 CheckBox。

  • 如果輸入有誤,通過 Toast 顯示相應(yīng)的錯(cuò)誤消息,并返回。

  • 如果輸入正確,使用 SharedPreferences 對(duì)象存儲(chǔ)用戶名和密碼。

  • 創(chuàng)建一個(gè) Intent,將用戶名和密碼作為額外數(shù)據(jù)存入 Bundle 中,并將 Bundle 放入 Intent 中。

  • 使用 setResult 方法設(shè)置活動(dòng)的返回結(jié)果為注冊(cè)成功,并將 Intent 傳遞給上一個(gè)活動(dòng)。

  • 通過 Toast 顯示注冊(cè)成功的消息,并關(guān)閉當(dāng)前活動(dòng)。

總之,這段代碼實(shí)現(xiàn)了一個(gè)簡(jiǎn)單的用戶注冊(cè)界面,用戶需要輸入用戶名、密碼、確認(rèn)密碼,勾選用戶協(xié)議后,點(diǎn)擊注冊(cè)按鈕即可完成注冊(cè)。注冊(cè)成功后,用戶名和密碼會(huì)被保存,并傳遞給調(diào)用該界面的上一個(gè)活動(dòng)。如果有任何輸入錯(cuò)誤或未勾選用戶協(xié)議,會(huì)通過 Toast 提示用戶相應(yīng)的錯(cuò)誤信息。

ic_login_background.png

android登錄注冊(cè)完整代碼,Android開源項(xiàng)目,android,android studio,java

activity_login.xml

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
 ? ?xmlns:app="http://schemas.android.com/apk/res-auto"
 ? ?xmlns:tools="http://schemas.android.com/tools"
 ? ?android:layout_width="match_parent"
 ? ?android:layout_height="match_parent"
 ? ?android:orientation="vertical"
 ? ?tools:context="com.example.login.LoginActivity"
 ? ?android:background="@drawable/ic_login_background">
?
 ? ?<LinearLayout
 ? ? ? ?android:layout_width="match_parent"
 ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ?android:orientation="horizontal"
 ? ? ? ?android:layout_marginLeft="20dp"
 ? ? ? ?android:layout_marginRight="20dp"
 ? ? ? ?android:layout_marginTop="40dp"
 ? ? ? ?android:gravity="center_vertical"
 ? ? ? ?>
 ? ? ? ?<TextView
 ? ? ? ? ? ?android:layout_width="wrap_content"
 ? ? ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ? ? ?android:text="賬號(hào):"
 ? ? ? ? ? ?android:textSize="25sp"
?
 ? ? ? ? ? ?/>
?
 ? ? ? ?<EditText
 ? ? ? ? ? ?android:id="@+id/et_account"
 ? ? ? ? ? ?android:layout_width="match_parent"
 ? ? ? ? ? ?android:hint="請(qǐng)輸入用戶名或手機(jī)號(hào)"
 ? ? ? ? ? ?android:layout_marginLeft="10dp"
 ? ? ? ? ? ?style="@style/MyEditStyle"
 ? ? ? ? ? ?android:inputType="text"
 ? ? ? ? ? ?/>
 ? ?</LinearLayout>
?
 ? ?<LinearLayout
 ? ? ? ?android:layout_width="match_parent"
 ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ?android:orientation="horizontal"
 ? ? ? ?android:layout_marginLeft="20dp"
 ? ? ? ?android:layout_marginRight="20dp"
 ? ? ? ?android:layout_marginTop="20dp"
 ? ? ? ?android:gravity="center_vertical"
 ? ? ? ?>
 ? ? ? ?<TextView
 ? ? ? ? ? ?android:layout_width="wrap_content"
 ? ? ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ? ? ?android:text="密碼:"
 ? ? ? ? ? ?android:textSize="25sp"
?
 ? ? ? ? ? ?/>
?
 ? ? ? ?<EditText
 ? ? ? ? ? ?android:id="@+id/et_password"
 ? ? ? ? ? ?android:layout_width="match_parent"
 ? ? ? ? ? ?android:layout_height="50dp"
 ? ? ? ? ? ?android:hint="請(qǐng)輸入密碼"
 ? ? ? ? ? ?android:textSize="18sp"
 ? ? ? ? ? ?android:layout_marginLeft="10dp"
 ? ? ? ? ? ?android:paddingLeft="5dp"
 ? ? ? ? ? ?android:inputType="numberPassword"
 ? ? ? ? ? ?android:background="@drawable/edit_text_bg"
 ? ? ? ? ? ?/>
 ? ?</LinearLayout>
?
 ? ?<LinearLayout
 ? ? ? ?android:layout_width="match_parent"
 ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ?android:orientation="horizontal"
 ? ? ? ?android:gravity="center"
 ? ? ? ?android:layout_marginTop="20dp"
 ? ? ? ?android:layout_marginLeft="20dp"
 ? ? ? ?android:layout_marginRight="20dp"
 ? ? ? ?>
?
 ? ? ? ?<CheckBox
 ? ? ? ? ? ?android:id="@+id/cb_remember"
 ? ? ? ? ? ?android:layout_width="wrap_content"
 ? ? ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ? ? ?android:text="記住密碼"
 ? ? ? ? ? ?/>
?
 ? ? ? ?<CheckBox
 ? ? ? ? ? ?android:id="@+id/cb_auto_login"
 ? ? ? ? ? ?android:layout_width="wrap_content"
 ? ? ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ? ? ?android:layout_marginLeft="40dp"
 ? ? ? ? ? ?android:text="自動(dòng)登錄"
 ? ? ? ? ? ?android:visibility="visible" />
?
 ? ?</LinearLayout>
?
 ? ?<Button
 ? ? ? ?android:id="@+id/btn_login"
 ? ? ? ?android:layout_width="match_parent"
 ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ?android:text="登錄"
 ? ? ? ?style="@style/MyBtnStyle"
 ? ? ? ?/>
?
 ? ?<TextView
 ? ? ? ?android:layout_width="wrap_content"
 ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ?android:textColor="@color/colorPrimary"
 ? ? ? ?android:text="還沒有賬號(hào)?"
 ? ? ? ?android:layout_gravity="right"
 ? ? ? ?android:layout_marginRight="20dp"
 ? ? ? ?android:layout_marginTop="10dp"
 ? ? ? ?android:onClick="toRegister"
 ? ? ? ?/>
?
?
?
</LinearLayout>

activity_register.xml

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
 ? ?xmlns:app="http://schemas.android.com/apk/res-auto"
 ? ?xmlns:tools="http://schemas.android.com/tools"
 ? ?android:layout_width="match_parent"
 ? ?android:layout_height="match_parent"
 ? ?android:orientation="vertical"
 ? ?tools:context="com.example.login.RegisterActivity">
?
 ? ?<LinearLayout
 ? ? ? ?android:layout_width="match_parent"
 ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ?android:layout_marginLeft="20dp"
 ? ? ? ?android:layout_marginTop="40dp"
 ? ? ? ?android:layout_marginRight="20dp"
 ? ? ? ?android:gravity="center_vertical"
 ? ? ? ?android:orientation="horizontal">
?
 ? ? ? ?<TextView
 ? ? ? ? ? ?android:layout_width="wrap_content"
 ? ? ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ? ? ?android:text="賬&#12288;&#12288;號(hào):"
 ? ? ? ? ? ?android:textSize="25sp" />
?
 ? ? ? ?<EditText
 ? ? ? ? ? ?android:id="@+id/et_account"
 ? ? ? ? ? ?style="@style/MyEditStyle"
 ? ? ? ? ? ?android:layout_width="match_parent"
 ? ? ? ? ? ?android:layout_marginLeft="10dp"
 ? ? ? ? ? ?android:hint="請(qǐng)輸入用戶名或手機(jī)號(hào)"
 ? ? ? ? ? ?android:inputType="text" />
 ? ?</LinearLayout>
?
 ? ?<LinearLayout
 ? ? ? ?android:layout_width="match_parent"
 ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ?android:layout_marginLeft="20dp"
 ? ? ? ?android:layout_marginTop="20dp"
 ? ? ? ?android:layout_marginRight="20dp"
 ? ? ? ?android:gravity="center_vertical"
 ? ? ? ?android:orientation="horizontal">
?
 ? ? ? ?<TextView
 ? ? ? ? ? ?android:layout_width="wrap_content"
 ? ? ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ? ? ?android:text="密&#12288;&#12288;碼:"
 ? ? ? ? ? ?android:textSize="25sp"
 ? ? ? ? ? ?/>
?
 ? ? ? ?<EditText
 ? ? ? ? ? ?android:id="@+id/et_password"
 ? ? ? ? ? ?style="@style/MyEditStyle"
 ? ? ? ? ? ?android:layout_width="match_parent"
 ? ? ? ? ? ?android:layout_marginLeft="10dp"
 ? ? ? ? ? ?android:hint="請(qǐng)輸入密碼"
 ? ? ? ? ? ?android:inputType="numberPassword" />
 ? ?</LinearLayout>
?
 ? ?<LinearLayout
 ? ? ? ?android:layout_width="match_parent"
 ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ?android:layout_marginLeft="20dp"
 ? ? ? ?android:layout_marginTop="20dp"
 ? ? ? ?android:layout_marginRight="20dp"
 ? ? ? ?android:gravity="center_vertical"
 ? ? ? ?android:orientation="horizontal">
?
 ? ? ? ?<TextView
 ? ? ? ? ? ?android:layout_width="wrap_content"
 ? ? ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ? ? ?android:text="確認(rèn)密碼:"
 ? ? ? ? ? ?android:textSize="25sp"
?
 ? ? ? ? ? ?/>
?
 ? ? ? ?<EditText
 ? ? ? ? ? ?android:id="@+id/et_password_confirm"
 ? ? ? ? ? ?style="@style/MyEditStyle"
 ? ? ? ? ? ?android:layout_width="match_parent"
 ? ? ? ? ? ?android:layout_marginLeft="10dp"
 ? ? ? ? ? ?android:hint="再次輸入密碼"
 ? ? ? ? ? ?android:inputType="numberPassword" />
 ? ?</LinearLayout>
?
 ? ?<Button
 ? ? ? ?android:id="@+id/btn_register"
 ? ? ? ?style="@style/MyBtnStyle"
 ? ? ? ?android:layout_width="match_parent"
 ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ?android:text="注冊(cè)" />
?
 ? ?<CheckBox
 ? ? ? ?android:id="@+id/cb_agree"
 ? ? ? ?android:layout_width="wrap_content"
 ? ? ? ?android:layout_height="wrap_content"
 ? ? ? ?android:layout_gravity="left"
 ? ? ? ?android:layout_marginLeft="20dp"
 ? ? ? ?android:layout_marginTop="10dp"
 ? ? ? ?android:text="勾選即同意用戶協(xié)議"
 ? ? ? ?android:textColor="@color/colorPrimary" />
?
?
</LinearLayout>

三.項(xiàng)目源碼

鏈接:百度網(wǎng)盤 請(qǐng)輸入提取碼** 提取碼:jynl

創(chuàng)作不易(可做實(shí)驗(yàn)報(bào)告,代碼講解等)

請(qǐng)私信作者或

(v)15135757306文章來源地址http://www.zghlxwxcb.cn/news/detail-637475.html

到了這里,關(guān)于Android安卓實(shí)戰(zhàn)項(xiàng)目---登陸注冊(cè)頁面(源碼在文末)的文章就介紹完了。如果您還想了解更多內(nèi)容,請(qǐng)?jiān)谟疑辖撬阉鱐OY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!

本文來自互聯(lián)網(wǎng)用戶投稿,該文觀點(diǎn)僅代表作者本人,不代表本站立場(chǎng)。本站僅提供信息存儲(chǔ)空間服務(wù),不擁有所有權(quán),不承擔(dān)相關(guān)法律責(zé)任。如若轉(zhuǎn)載,請(qǐng)注明出處: 如若內(nèi)容造成侵權(quán)/違法違規(guī)/事實(shí)不符,請(qǐng)點(diǎn)擊違法舉報(bào)進(jìn)行投訴反饋,一經(jīng)查實(shí),立即刪除!

領(lǐng)支付寶紅包贊助服務(wù)器費(fèi)用

相關(guān)文章

  • 【免費(fèi)開放源碼】審批類小程序項(xiàng)目實(shí)戰(zhàn)(注冊(cè)登錄頁面)

    【免費(fèi)開放源碼】審批類小程序項(xiàng)目實(shí)戰(zhàn)(注冊(cè)登錄頁面)

    第一節(jié):什么構(gòu)成了微信小程序、創(chuàng)建一個(gè)自己的小程序 第二節(jié):微信開發(fā)者工具使用教程 第三節(jié):深入了解并掌握小程序核心組件 第四節(jié):初始化云函數(shù)和數(shù)據(jù)庫 第五節(jié):云數(shù)據(jù)庫的增刪改查 第六節(jié):項(xiàng)目大綱以及制作登錄、注冊(cè)頁面 第七節(jié):制作活動(dòng)申請(qǐng)頁面 第八節(jié)

    2024年02月16日
    瀏覽(22)
  • 菜鳥Vue教程 - 實(shí)現(xiàn)帶國際化的注冊(cè)登陸頁面

    菜鳥Vue教程 - 實(shí)現(xiàn)帶國際化的注冊(cè)登陸頁面

    初接觸vue的時(shí)候覺得vue好難,因?yàn)轫?xiàng)目中要用到,就硬著頭皮上,慢慢的發(fā)現(xiàn)也不難,無外乎畫個(gè)布局,然后通過樣式調(diào)整界面。在通過屬性和方法跟js交互。js就和我們寫的java代碼差不多了,復(fù)雜一點(diǎn)的就是引用這種那種庫,然后就能做出來一個(gè)界面了。如果你的項(xiàng)目就是

    2024年02月12日
    瀏覽(20)
  • 基于Vue+ELement搭建登陸注冊(cè)頁面實(shí)現(xiàn)后端交互

    基于Vue+ELement搭建登陸注冊(cè)頁面實(shí)現(xiàn)后端交互

    ????歡迎來到我的CSDN主頁!???? ??我是Java方文山,一個(gè)在CSDN分享筆記的博主。???? ??推薦給大家我的專欄《ELement》。???? ??點(diǎn)擊這里,就可以查看我的主頁啦!???? Java方文山的個(gè)人主頁 ??如果感覺還不錯(cuò)的話請(qǐng)給我點(diǎn)贊吧!???? ??期待你的加入,一起學(xué)習(xí)

    2024年02月08日
    瀏覽(26)
  • SpringBoot實(shí)現(xiàn)登陸注冊(cè)(附源碼)

    SpringBoot實(shí)現(xiàn)登陸注冊(cè)(附源碼)

    ? ? ? ? 先看看我的項(xiàng)目總結(jié)吧: 先說完美的吧,因?yàn)榍岸说顷懽?cè)界面是之前的,這次就復(fù)制了一下,在前端部分僅書寫了一些vue,使用v-model綁定username以及password,發(fā)送axios請(qǐng)求,后端那部分因?yàn)槭褂玫氖莔ybatis-plus,也沒有編寫一些sql語句,當(dāng)然,這些sql語句也不是很復(fù)

    2024年02月11日
    瀏覽(22)
  • Vue3+element-plus 后臺(tái)管理系統(tǒng)(含登陸注冊(cè)功能頁面)

    Vue3+element-plus 后臺(tái)管理系統(tǒng)(含登陸注冊(cè)功能頁面)

    最近在學(xué)習(xí)Vue3,記錄一下自己從0開始搭建后臺(tái)框架,并獲取遠(yuǎn)程接口數(shù)據(jù)對(duì)頁面的渲染 本次功能實(shí)現(xiàn)主要包括:連接后端的遠(yuǎn)程接口數(shù)據(jù)進(jìn)行登錄注冊(cè)功能實(shí)現(xiàn) : 1.本次登陸注冊(cè)合并為了一個(gè)頁面,頁面都使用了element-plus中的組件渲染,更加美觀 2.用route路由實(shí)現(xiàn)不同頁面邏輯跳

    2023年04月26日
    瀏覽(22)
  • Vue項(xiàng)目實(shí)戰(zhàn)——【基于 Vue3.x + Vant UI】實(shí)現(xiàn)一個(gè)多功能記賬本(登錄注冊(cè)頁面,驗(yàn)證碼)

    Vue項(xiàng)目實(shí)戰(zhàn)——【基于 Vue3.x + Vant UI】實(shí)現(xiàn)一個(gè)多功能記賬本(登錄注冊(cè)頁面,驗(yàn)證碼)

    系列內(nèi)容 參考鏈接 基于 Vue3.x + Vant UI 的多功能記賬本(一) 項(xiàng)目演示,涉及知識(shí)點(diǎn) 基于 Vue3.x + Vant UI 的多功能記賬本(二) 搭建開發(fā)環(huán)境 基于 Vue3.x + Vant UI 的多功能記賬本(三) 開發(fā)導(dǎo)航欄及公共部分 項(xiàng)目演示 Vue3 + Vant UI_多功能記賬本 1、登錄注冊(cè)頁面 頁面設(shè)計(jì),頁面

    2024年02月03日
    瀏覽(172)
  • 100套安卓(Android)畢業(yè)設(shè)計(jì)(帶論文)、大作業(yè)、現(xiàn)成作品(Android Studio)Android畢業(yè)設(shè)計(jì)項(xiàng)目,源碼+論文

    100套安卓(Android)畢業(yè)設(shè)計(jì)(帶論文)、大作業(yè)、現(xiàn)成作品(Android Studio)Android畢業(yè)設(shè)計(jì)項(xiàng)目,源碼+論文

    1,基于Android 語音朗讀書籍管理系統(tǒng) 畢業(yè)設(shè)計(jì) 2,基于Android圖書管理系統(tǒng)? ?畢業(yè)設(shè)計(jì) 3,基于 Android系統(tǒng)藍(lán)牙通信呼吸檢測(cè)設(shè)備管理系統(tǒng)? 4,基于Android+java后臺(tái)管理掛號(hào)系統(tǒng)? 畢業(yè)設(shè)計(jì) 5,基于Android系統(tǒng)的JT808協(xié)議傳輸定位信息系統(tǒng)?畢業(yè)設(shè)計(jì) 6,基于Android生鮮食品管理系統(tǒng)

    2024年02月05日
    瀏覽(31)
  • Java-Web前后端交互實(shí)現(xiàn)登陸注冊(cè)(附源碼)

    Java-Web前后端交互實(shí)現(xiàn)登陸注冊(cè)(附源碼)

    1.完成用戶登錄功能。 2.完成注冊(cè)功能。 3.主體利用Maven導(dǎo)入java中的jar包,使用Servlet實(shí)現(xiàn)前后端交互,使用mybatis以及注解,mysql進(jìn)行數(shù)據(jù)保存,Tomcat服務(wù)器進(jìn)行開發(fā)。 效果圖 項(xiàng)目結(jié)構(gòu) 代碼 mapper(相對(duì)應(yīng)注解) pojo(實(shí)體類) 3.util(工具類) 4.web(Servlet) 1.loginServlet 2.registerServlet

    2023年04月21日
    瀏覽(19)
  • Android studio - UI 界面設(shè)計(jì)(仿問卷星登陸注冊(cè)界面)

    Android studio - UI 界面設(shè)計(jì)(仿問卷星登陸注冊(cè)界面)

    1 先上效果圖: 2 準(zhǔn)備工作 建如下活動(dòng)文件以及素材文件 3 代碼實(shí)現(xiàn) 3.1 修改themes.xml、 themes.xml(night)文件 使自定義按鈕組件起效果 代碼實(shí)現(xiàn) btn_login.xml button_lg.xml button_res.xml 3.2 實(shí)現(xiàn)布局 3.2.1 登陸界面 activity_login.xml 3.2.2 注冊(cè)界面 activity_register.xml 4 按鈕實(shí)現(xiàn)頁面跳轉(zhuǎn) 4.1 Logi

    2024年02月11日
    瀏覽(34)
  • PHP注冊(cè)、登陸、6套主頁-帶Thinkphp目錄解析-【白嫖項(xiàng)目】

    PHP注冊(cè)、登陸、6套主頁-帶Thinkphp目錄解析-【白嫖項(xiàng)目】

    強(qiáng)擼項(xiàng)目系列總目錄在000集 PHP要怎么學(xué)–【思維導(dǎo)圖知識(shí)范圍】 用免費(fèi)公開視頻,卷飛培訓(xùn)班哈人!打死不報(bào)班,賺錢靠狠干! 只要自己有電腦,前后項(xiàng)目都能搞!N年苦學(xué)無人問,一朝成名天下知! PHP無類 PHP類寫法 ThinkPHP框架 其它框架 *5.0 環(huán)境 PHP版本 mysql版本

    2024年02月15日
    瀏覽(25)

覺得文章有用就打賞一下文章作者

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

請(qǐng)作者喝杯咖啡吧~博客贊助

支付寶掃一掃領(lǐng)取紅包,優(yōu)惠每天領(lǐng)

二維碼1

領(lǐng)取紅包

二維碼2

領(lǐng)紅包