Exemple #1
0
 /// <summary>
 /// 返回用户名
 /// </summary>
 /// <returns>返回用户名,未登录返回空</returns>
 public string TrueName()
 {
     if (!User.Identity.IsAuthenticated)
     {
         return("no");
     }
     try
     {
         return(HttpContext.Server.UrlEncode(new SOSOshop.BLL.Db().ExecuteScalarForCache("SELECT TrueName FROM dbo.memberinfo WHERE UID=" + BaseController.GetUserId()).ToString().Trim()));
     }
     catch
     {
         return("no");
     }
 }