Files
shape3d.it/public/api/printers.php
2025-11-17 23:56:51 +01:00

7 lines
262 B
PHP
Executable File

<?php
// public/api/printers.php
header('Content-Type: application/json; charset=utf-8');
require __DIR__ . '/_db.php';
$stmt = $pdo->query("SELECT * FROM printers WHERE is_active = 1 ORDER BY name");
echo json_encode($stmt->fetchAll(), JSON_UNESCAPED_UNICODE);