ASP.NET ½Å±¾¹ýÂË ·ÀÖ¹¿çÕ¾½Å±¾¹¥»÷
/// <summary>
/// HTML½âÂë
/// </summary>
/// <param name="input"></param>
/// <returns></returns>
public string HtmlDecode(string input)
{
StringBuilder sb = new StringBuilder(
HttpUtility.HtmlDecode(input));
return sb.ToString();
}
/// <summary>
/// HTML±àÂë
/// </summary>
/// <param name="input"></param>
/// <returns></returns>
public string HtmlEncode(string input)
{
StringBuilder sb = new StringBuilder(
HttpUtility.HtmlEncode(input));
//Ñ¡ÔñÐÔµÄÔÊÐí<b> ºÍ <i>
sb.Replace("<b>", "<b>");
sb.Replace("</b>", "");
sb.Replace("<i>", "<i>");
sb.Replace("</i>", "");
return sb.ToString();
}
Ïà¹ØÎĵµ£º
//ExcelÅúÁ¿µ¼Èëµ½Êý¾Ý¿â
protected void btnUpload_Click(object sender, EventArgs e)
{
string IsXls = System.IO.Path.GetExtension(UploadExcel.FileName.ToString().ToLower ......
ASP.NET Cookies¼òµ¥Ó¦Óà ¼ÇסÓû§ÃûºÍÃÜÂë
ASP.NET Cookies¼òµ¥Ó¦Óà ¼ÇסÓû§ÃûºÍÃÜÂë
2009-06-11 22:45
±¾ÎÄת×Ôhttp://www.cnblogs.com/wayne-ivan/archive/2008/12/18/1357628.html
²»ÒªÊÔͼ¸øPasswordÀàÐ͵ÄTextBox¸³Öµ!
ÔÚasp.netÖУ¬²»ÒªÊÔͼ¸øPasswordÀàÐ͵ÄTextBox¿Ø¼þ¸³Öµ! ÎÞÂÛÊÇÔÚÉè¼Æ»òÊÇÔËÐÐʱ ......
1¡¢Ê¹ÓÃPage.ClientScript.RegisterClientScriptBlock
RegisterClientScriptBlock·½·¨¿ÉÒÔ°ÑJavaScriptº¯Êý·ÅÔÚÒ³ÃæµÄ¶¥²¿¡£Ò²¾ÍÊÇ˵£¬¸Ã½Å±¾ÓÃÓÚÔÚä¯ÀÀÆ÷ÖÐÆô¶¯Ò³Ãæ¡£
Code
<%@ Page Language="C#" %>
<script runat="server">
protected void Page_Load(object send ......
.netÖкÎÓÐЧµÄʹÓÃCache
Cache ¼´¸ßËÙ»º´æ £¬ÄÇôcacheÊÇÈçºÎÌá¸ßϵͳÐÔÄÜÓëÔËÐÐËÙ¶ÈÄØ£¿ÊDz»ÊÇÔÚÈκÎÇé¿öÏÂÓÃcache¶¼ÄÜÌá¸ßÐÔÄÜ£¿ÊDz»ÊÇcacheÓõÄÔ½¶à¾ÍÔ½ºÃÄØ£¿ÏÂÃæÊÇ×ܽ᣺
1. Cache ÊÇÈçºÎ¹¤×÷µÄ l Cache ÊÇ·ÖÅ ......
http://www.codeproject.com/KB/aspnet/ASPDOTNETPageLifecycle.aspx?msg=3443071#xx3443071xx
ASP.NET application and page life cycle
Introduction
The Two step process
Creation of ASP.NET environment
Process request using MHPM events fired
In What event we should do what?
A sample code for demons ......