<?php include_once 'config.php'; include_once 'process.php'; // $sql = "INSERT INTO test (name,age) VALUES (:name,:age)"; // $q = $pdo->prepare($sql); // $q->execute(array(':name'=>$_POST['name'],':age'= $_POST['age'])); $id = $_POST['id']; // $sql = "UPDATE temp SET test = '1' WHERE id=:id"; // $q = $pdo->prepare($sql); // $q->execute(array(':id'=>$id)); update_temp_member($id, $pdo); //echo $id;
include_once 'config.php'; include_once 'process.php'; // if(isset($_POST['add'])) // { // // echo "Add -> ".$_POST['add']."<br>"; // // } //$id = $_POST['add']; // update_temp_member($id,$pdo); // //echo $name; // if(isset($_POST['del'])) // { // echo "del -> ".$_POST['del']."<br>"; // delete_temp_member($id,$pdo); // } $add = $_POST['add']; $del = $_POST['del']; $opp = $_POST['opp']; if ($opp == "del") { delete_temp_member($del, $pdo); } else { if ($opp == "add") { update_temp_member($add, $pdo); } } //echo "opp - >" . $opp . " " . $add . " " . $del ; ?>