摘要: 第十一节 10图片权限控制?用户名:密 码: ?usingSystem;usingSystem.Collections.Generic;usingSystem.Linq;usingSystem.Web;usingSystem.Web.UI;usingSystem.Web.UI.WebControls;usingSystem.Data.SqlClient;usingSystem.Data;/* 练习: 用户表增加一个级别字段,只有登妹用户才能下载images下的图片文件(session中标识是否登陆)* 如查用户没有登陆则首先重定向到登录界面让用户登录* 用户登妹成功则跳转到下载列表页面,下载. 阅读全文
posted @ 2013-07-19 19:42 笨笨丫头~双 阅读(319) 评论(0) 推荐(0) 编辑
摘要: (前台) --%> ' runat="server" Width="100px" /> ' runat="server" Width="200px" /> ' runat="server" AutoPostBack="true" Width="50px" /> ' runat="server" Width="100px" /> (后台)public par 阅读全文
posted @ 2013-07-19 19:30 笨笨丫头~双 阅读(626) 评论(0) 推荐(0) 编辑
摘要: (前台) 用户名评论内容时间 (后台)protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { string str1 = @"server=Rose-PC\SQLEXPRESS;Database=New;User Id=sa;password= "; string str2 = "select * from T_discussInfo"; using (SqlConnection conn = new SqlConnection(str1)) { conn.Ope 阅读全文
posted @ 2013-07-19 19:20 笨笨丫头~双 阅读(222) 评论(0) 推荐(0) 编辑
摘要: (前台代码) 热点 国际 国内 体育 女性 教育 财经 Java 军事 娱乐 (后台代码) public static int IntSearch; protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { IntSearch = 0; int n = Convert.ToInt32(Request.QueryString["ID"]); this.ddtype.SelectedIndex = (n - 1); this.bind();}protected void bind() { 阅读全文
posted @ 2013-07-19 19:15 笨笨丫头~双 阅读(179) 评论(0) 推荐(0) 编辑
摘要: ------------vote.aspx.cs--------------------private void Page_Load(object sender, System.EventArgs e) { // 在此处放置用户代码以初始化页面 if(!Page.IsPostBack) { SqlConnection con=db.createrConnection(); con.Open(); SqlCommand cmd=new SqlCommand("select votetitle from votemaster where voteid="+this.idd,co 阅读全文
posted @ 2013-07-19 14:24 笨笨丫头~双 阅读(505) 评论(0) 推荐(0) 编辑