diff --git a/abi/addabi.php b/abi/addabi.php deleted file mode 100644 index 074c090..0000000 --- a/abi/addabi.php +++ /dev/null @@ -1,40 +0,0 @@ -beginTransaction(); - - $stmt = $pdo->prepare("UPDATE ueuse SET abi = :abi, abidate = :abidate WHERE uniqid = :uniqid"); - $stmt->bindValue(':abi', $abitext, PDO::PARAM_STR); - $stmt->bindValue(':abidate', $abidate, PDO::PARAM_STR); - $stmt->bindValue(':uniqid', $postUniqid, PDO::PARAM_STR); - - // SQLクエリの実行 - $res = $stmt->execute(); - - // コミット - $pdo->commit(); - - if ($res) { - header('Content-Type: application/json'); - echo json_encode(['success' => true]); - exit; - } else { - header('Content-Type: application/json'); - echo json_encode(['success' => false, 'error' => '追加に失敗しました。']); - exit; - } - } catch(PDOException $e) { - header('Content-Type: application/json'); - echo json_encode(['success' => false, 'error' => 'データベースエラー:' . $e->getMessage()]); - exit; - } -} -?>