我是Android工作室的菜鸟......目前正处于学习阶段......我在这个社区复制了@ Nirav-Kalola的代码。每当在Android刷卡中向左或向右滑动时,我都需要帮助将布尔值传递到服务器。 以下是代码:
<?php
session_start();
if(!isset($_SESSION['user_type']=='1']) OR $_SESSION['userid']==''){
header('Location: Loginhome.php');
}
else
if(isset($_SESSION['user_type']=='2']) && $_SESSION['user_type'] =='Admin'){
header('Location: adminhome.php');
}
else{
header('Location: userhome.php');
exit;
}
?>
答案 0 :(得分:0)
只需使用这两种方法进行网络通话
@Override
public void onLeftCardExit(Object dataObject) {
al.remove(0);
myAppAdapter.notifyDataSetChanged();
//Do something on the left!
//You also have access to the original object.
//If you want to use it just cast it (String) dataObject
}
@Override
public void onRightCardExit(Object dataObject) {
al.remove(0);
myAppAdapter.notifyDataSetChanged();
}