synonim pages and new dump

This commit is contained in:
2024-10-10 12:16:59 +02:00
parent c3ddf47a7e
commit 59243c754b
22 changed files with 2373 additions and 62534 deletions
@@ -0,0 +1,22 @@
<?php
include('../include/headscript.php');
include("../class/company.php");
$conn = new mysqli($servername, $username, $password, $database);
if (isset($_POST['id'])) {
$refid = $_POST['id'];
// Recupera i sinonimi per il composto specifico
$stmt = $conn->prepare("SELECT * FROM compundsvocabulary WHERE refid = ? AND preferred = 'N'");
$stmt->bind_param('i', $refid);
$stmt->execute();
$result = $stmt->get_result();
$data = [];
while ($row = $result->fetch_assoc()) {
$data[] = $row;
}
echo json_encode($data);
} else {
echo json_encode(['success' => false, 'error' => 'Invalid input']);
}