Collapse Sidebar on CurrentUserLevel()

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
mpol_ch
User
Posts: 877
Location: Switzerland

Collapse Sidebar on CurrentUserLevel()

Post by mpol_ch »

Hi,

how can I collapse the sidebar on checking of CurrentUserLevel()?
I am using v2024_07

  function Menu_Rendering() {
   if (CurrentUserLevel() == 0 ) // sidebar menu
      *** Then Collapse Sidebar*** 
  }

Could you help me with a hint?

mpol_ch


arbei
User
Posts: 9384

Post by arbei »

  1. Sidebar is abn AdminLTE widget in HTML/CS/JS, it is not related to menu or Menu_* server events.
  2. To collapse the sidebar you need to the "sidebar-collapse" CSS class to the <body> tag, you can use Page_Rendering server event to change the Config("BODY_CLASS"), also see Config($name[, $value]).

Post Reply