Webpage for Games
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

17 lines
461 B

<?php
$response_array = array();
include_once $_SERVER['DOCUMENT_ROOT'] . '/../private/mysql_connect.php';
$conn = new MySQLConnection();
$content = $_POST['content'];
$projectName = $_POST['projectName'];
$sql = "INSERT INTO feedbacks (content, project_name)
VALUES ('$content', '$projectName')";
$result = $conn->query($sql);
$response_array['result'] = json_encode($result);
header('Content-type: application/json');
echo json_encode($response_array);