From 90483f6eb389f041e0dbd0fca8bb766edbc85910 Mon Sep 17 00:00:00 2001 From: chai Date: Thu, 17 Mar 2022 21:02:13 +0800 Subject: +init --- connect.php | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 connect.php (limited to 'connect.php') diff --git a/connect.php b/connect.php new file mode 100644 index 0000000..8787da3 --- /dev/null +++ b/connect.php @@ -0,0 +1,27 @@ + + +connect_error) { + die("连接失败: " . $conn->connect_error); + return ; + } + } + return mysqli_query($conn, $sql); +} + +function get_last_insert_id() { + global $conn; + return mysqli_insert_id($conn); +} + +?> \ No newline at end of file -- cgit v1.1-26-g67d0