Initial commit
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
include 'db.php';
|
||||
|
||||
$data = json_decode(file_get_contents("php://input"));
|
||||
|
||||
$coords = json_encode($data->coordinates);
|
||||
|
||||
$sql = "INSERT INTO polygons (coordinates) VALUES ('$coords')";
|
||||
|
||||
$conn->query($sql);
|
||||
|
||||
echo json_encode(["status"=>"ok"]);
|
||||
?>
|
||||
Reference in New Issue
Block a user