示例#1
0
                            //成功!
                            header("Location:ok.php");
                            exit;
                        } else {
                            header("Location:error.php");
                            exit;
                        }
                    } else {
                        if ($flag == "Useraddemp") {
                            //说明用户希望执行添加用户
                            //接收数据
                            $id = $_POST['id'];
                            $name = $_POST['name'];
                            $password = $_POST['password'];
                            //完成添加->数据
                            $res = $empService->Useraddemp($id, $name, $password);
                            if ($res == 1) {
                                //成功!
                                header("Location:ok.php");
                                exit;
                            } else {
                                header("Location:error.php");
                                exit;
                            }
                        }
                    }
                }
            }
        }
    }
}