common.php 1.1 KB

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. // +---------------------------------------------------------------------+
  3. // | OneBase | [ WE CAN DO IT JUST THINK ] |
  4. // +---------------------------------------------------------------------+
  5. // | Licensed | http://www.apache.org/licenses/LICENSE-2.0 ) |
  6. // +---------------------------------------------------------------------+
  7. // | Author | Bigotry <3162875@qq.com> |
  8. // +---------------------------------------------------------------------+
  9. // | Repository | https://gitee.com/Bigotry/OneBase |
  10. // +---------------------------------------------------------------------+
  11. /**
  12. * 应用公共(函数)文件
  13. */
  14. use think\Db;
  15. use think\Response;
  16. use think\exception\HttpResponseException;
  17. // +---------------------------------------------------------------------+
  18. // | 系统相关函数
  19. // +---------------------------------------------------------------------+
  20. /**
  21. * 清除登录 session
  22. */
  23. function clear_login_session()
  24. {
  25. session('user_info', null);
  26. }