31 lines
999 B
C#
31 lines
999 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Web;
|
|
using System.Web.UI;
|
|
using System.Web.UI.WebControls;
|
|
|
|
namespace CitySunlight
|
|
{
|
|
public partial class Basic : System.Web.UI.MasterPage
|
|
{
|
|
protected void Page_Load(object sender, EventArgs e)
|
|
{
|
|
|
|
}
|
|
public String GetLoginInfo()
|
|
{
|
|
String html = "";
|
|
if (Session["username"] == null)
|
|
html = "<li><a href=\"/Account/Login.aspx\" >登录</a></li>";
|
|
else
|
|
{
|
|
html = String.Format("<li><a href=\"#\" >欢迎您 {0} </a></li>", Session["username"].ToString());
|
|
html += "<li><a href=\"/Account/LogOut.aspx\" >注销</a></li>";
|
|
html += "<li><a href=\"/Product/ProductEdit.aspx?type=create\" >发布</a></li>";
|
|
html += "<li><a href=\"/Admin.aspx\" >管理</a></li>";
|
|
}
|
|
return html;
|
|
}
|
|
}
|
|
} |