![]() Server : Apache/2 System : Linux server-15-235-50-60 5.15.0-164-generic #174-Ubuntu SMP Fri Nov 14 20:25:16 UTC 2025 x86_64 User : gositeme ( 1004) PHP Version : 8.2.29 Disable Function : exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname Directory : /home/gositeme/.cursor-server/data/User/History/-56a8c7f6/ |
<?php
session_start();
// Admin user credentials
$admin_email = 'admin@soundstudiopro.com';
$admin_password = 'admin123'; // You may need to change this
require_once 'config/database.php';
$pdo = getDBConnection();
// Check if admin exists and verify password
$stmt = $pdo->prepare("SELECT * FROM users WHERE email = ? AND is_admin = 1");
$stmt->execute([$admin_email]);
$admin = $stmt->fetch();
if ($admin) {
// Set admin session
$_SESSION['user_id'] = $admin['id'];
$_SESSION['username'] = $admin['name'];
$_SESSION['email'] = $admin['email'];
$_SESSION['credits'] = $admin['credits'];
$_SESSION['plan'] = $admin['plan'];
$_SESSION['is_admin'] = $admin['is_admin'];
echo "✅ Successfully logged in as admin!<br>";
echo "Admin ID: " . $admin['id'] . "<br>";
echo "Admin Name: " . $admin['name'] . "<br>";
echo "Admin Email: " . $admin['email'] . "<br>";
echo "Is Admin: " . ($admin['is_admin'] ? 'Yes' : 'No') . "<br>";
echo "<br>";
echo "<a href='admin.php' style='background: #667eea; color: white; padding: 10px 20px; text-decoration: none; border-radius: 5px;'>Go to Admin Panel</a>";
} else {
echo "❌ Admin user not found or not an admin";
}
?>