<?php
require __DIR__ . '/../db_config.php';

$candidates = ['login-t','login_table','login','logins','login_table_old','login-table','login_t','users_old', 'user_login','logininfo','logininfo_tbl'];
foreach ($candidates as $t) {
    $res = $conn->query("DESCRIBE `{$t}`");
    if ($res && $res->num_rows > 0) {
        echo "Found table: {$t}\n";
        while ($r = $res->fetch_assoc()) {
            echo "  {$r['Field']} {$r['Type']} {$r['Null']}\n";
        }
        echo "\n";
    }
}

// Also list all tables as a fallback
$all = $conn->query('SHOW TABLES');
if ($all) {
    echo "All tables:\n";
    while ($r = $all->fetch_row()) echo "  {$r[0]}\n";
}

exit(0);
