SiteAdmin/Aspx/UserAdd.aspx.cs
(开头部分) 4KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using System.Data.SqlClient;
public partial class SiteAdmin_Aspx_UserAdd : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (Request.Cookies["roleid"] != null)
{
if (!IsPostBack)
{
}
}
else
{
MessageBox.ShowAndRedirect(this.Page, "对不起!您还没有登录系统。", "../Logout.aspx");
}
}
protected void LinkButton_Add_Click(object sender, EventArgs e)
{
string Name = TextBox_Name.Text.Trim();
string Password = TextBox_Pwd.Text.Trim();
string Realname = TextBox_RealName.Text.Trim();
int Group = Convert.ToInt32(DropDownList_Type.SelectedValue);
string Email = TextBox_Mail.Text.Trim();
string Phone = TextBox_Phone.Text.Trim();
try
{
Admin myuser = new Admin();
if (myuser.ExistsU(Name))
{
Response.Write("<script type=\"text/javascript\">alert(\"用户名已存在!\")</script>");
return;
}
else
{
myuser.UserName =Name;
myuser.PassWord =Password;
myuser.Name = Realname;
myuser.RoleID = Group;
myuser.Email =Email;
myuser.Phone = Phone;
myuser.LastIP = "";
myuser.LastVisit = DateTime.Now;
if (Group == 3)
{
myuser.JGID = Convert.ToInt32(DropDownList_jrjg.SelectedValue);
}
else if (Group == 4)
{
myuser.JGID = Convert.ToInt32(DropDownList_dbjg.SelectedValue);
后面还有 82 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。