<?php
require_once 'UserModel.php'; // adjust path if needed

try {
    $userModel = new UserModel();
    $id = $userModel->createUser('admin', 'Administrator', 'admin', 'admin');

    echo "<h3>✅ Admin user created successfully!</h3>";
    echo "<p>Username: <b>admin</b><br>Password: <b>admin</b></p>";
    echo "<p>User ID: {$id}</p>";
} catch (PDOException $e) {
    echo "<h3>⚠️ Error creating admin user:</h3>";
    echo "<pre>" . $e->getMessage() . "</pre>";
}
?>
