【问题标题】:ASP.Net - Checking User Details From Business LayerASP.Net - 从业务层检查用户详细信息
【发布时间】:2009-05-28 04:46:16
【问题描述】:

我正在使用 asp.net 配置管理器和标准登录控件来允许用户登录。

能否从业务层找到当前登录的用户,还是需要从 UI 中传入?

【问题讨论】:

    标签: asp.net authentication


    【解决方案1】:

    试试这个:

    HttpContext.Current.User.Identity.IsAuthenticated
    
    //OR you may put user into session and access it like this
    
    HttpContext.Current.Session["user"]
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2011-03-06
      • 2023-04-10
      • 1970-01-01
      • 1970-01-01
      • 2015-05-31
      • 2020-08-03
      • 1970-01-01
      • 2014-11-08
      相关资源
      最近更新 更多