<?php
include_once "{$_SERVER['DOCUMENT_ROOT']}/common.inc.php";
$menu_hist = array();
if( $GLOBALS['_Auth_']['menuObj'] ){
  $menu_hist = $GLOBALS['_Auth_']['menuObj']->getMenuBrdcom($GLOBALS['_Auth_']['cate_id']);
}

if( $menu_hist ){
  $GLOBALS['_Menu_'] = array(
    "menu_code" => $menu_hist['cate_code'][count($menu_hist['cate_id'])-1],
    "menu_name" => $menu_hist['cate_name'][count($menu_hist['cate_id'])-1],
    "menu_exp" => $menu_hist['cate_exp'][count($menu_hist['cate_id'])-1],
  );
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <?php include __DIR__."/header_common.html"?>
  <?php include __DIR__."/header_inc.html"?>

</head>

<?php include __DIR__."/header_frame.html"?>
<?php include __DIR__."/sidemenu.html"?>

    <div id="main">
      <div class="header-static">
        <div class="header-status">
          <div><i class="icon-title"><span class="bi bi-list btn-sidemenu"></span> <?=$GLOBALS['_Menu_']['menu_name']?></i> <?=$GLOBALS['_Menu_']['menu_exp']?></div>
          <div>
            <a href="###"><i class="bi bi-person-circle icon-link"> <?=$GLOBALS['_Umem']['member_name']?> (<?=$GLOBALS['_Umem']['member_id']?>)</i></a>
            <a href="javascript:logout();"><i class="bi bi-door-closed icon-link"> Logout</i></a>
          </div>
        </div>
        <div class="header-bcrumb">
          <i class="bi bi-caret-right mr-3"></i>
          <a href="<?=_ADM_URL_?>">Home</a>
          <?php if( $menu_hist ){?>
          <?php for( $a=0 ; $a<@count($menu_hist['cate_id']) ; $a++ ){?>

          <i class="bi bi-chevron-right ml-2 mr-2"></i> <a href="<?=$menu_hist['cate_data'][$a]?:"###"?>"><?=$menu_hist['cate_name'][$a]?></a>

          <?php }}?>
        </div>
      </div>
      <div class="body">