<?php
namespace App\Controllers\Admin;
use App\Controllers\BaseController;

class Tester extends BaseController {
    public function index() {
        echo "<h1>Cek Session Admin</h1>";
        echo "<pre>";
        print_r(session()->get());
        echo "</pre>";
        echo "<hr>";
        echo "Role Anda: " . session()->get('role') . "<br>";
        echo "Is Logged In: " . (session()->get('isLoggedIn') ? 'Ya' : 'Tidak') . "<br>";
        echo "<a href='".base_url('admin/struktur')."'>Coba Klik Ke Struktur</a>";
    }
}