I really wasn’t sure if I should use GET or POST
, I thought the opnly difference was using GET would put it in the url and POST did not, is that not the cas e?
heres the php file
<?php
if(isset($_GET['Type'] {
//$Type = $_GET['Type'];
//$sql = "INSERT INTO furniture_types (name) VALUES ('".$Type."')";
//mysqli_query($conn, $sql);
$stmt = $mysqli->prepare("INSERT INTO furniture_types (name) VALUES (?)");
$stmt->bind_param("s", $_GET['Type']);
$stmt->execute();
$stmt->close();
}
?>