Actualiser api.php

This commit is contained in:
2026-06-25 13:49:59 +02:00
parent 974c756790
commit 906e7b2e1d
+10
View File
@@ -643,5 +643,15 @@ switch ($action) {
echo json_encode($diag, JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE); echo json_encode($diag, JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE);
exit; exit;
break; break;
case 'test_dvdfr':
$url = "https://www.dvdfr.com/api/search.php?title=" . urlencode($_GET['title'] ?? 'Matrix');
$html = httpGet($url, 5);
echo json_encode([
'url' => $url,
'http_length' => $html ? strlen($html) : 0,
'snippet' => $html ? substr($html, 0, 300) : 'VIDE/ERREUR'
]);
break;
} }
?> ?>