PbootCMS判断登录状态

  • 问题描述:PbootCMS判断用户是否登录的代码。
  • 解决方法
    • 使用 JavaScript 判断 usermobile 是否存在来判断登录状态:
      <script type="text/javascript">
        {pboot@if({user:usermobile} == "")}
          window.location.href = {pboot:login};
        {/pboot@if}
      </script>

       

posted @ 2024-11-02 12:26  黄文Rex  阅读(38)  评论(0)    收藏  举报