diff --git a/backend/api/debug-hex.php b/backend/api/debug-hex.php new file mode 100644 index 0000000..f1cf07b --- /dev/null +++ b/backend/api/debug-hex.php @@ -0,0 +1,35 @@ += 32 && $c <= 126) ? $bytes[$i] : '.'; + } + + $results[$file] = [ + 'size' => filesize($path), + 'first_16_hex' => implode(' ', $hex), + 'first_16_ascii' => $ascii + ]; + } else { + $results[$file] = 'File not found'; + } +} + +echo json_encode($results, JSON_PRETTY_PRINT); +?>