Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ASP.NET

      ASP.NET Óû§ÅäÖÃÎļþ¹¦ÄÜÉè¼ÆΪÌṩµ±Ç°Óû§µÄ¶ÀÓÐÐÅÏ¢¡£ÅäÖÃÎļþ¿ÉÓÉͨ¹ýÉí·ÝÑéÖ¤µÄÓû§Ê¹Óã¬Ò²¿ÉÒÔÓÉÄäÃû£¨Î´¾­Éí·ÝÑéÖ¤£©Óû§Ê¹Óá£
 
1¡¢Í¨¹ýÉí·ÝÑéÖ¤µÄÓû§
ĬÈÏÇé¿öÏ£¬Óû§ÅäÖÃÎļþÓ뵱ǰ HTTP ÉÏÏÂÎÄ£¨¿Éͨ¹ý HttpContext..::.Current ÊôÐÔ·ÃÎÊ£©µÄ User ÊôÐÔÖд洢µÄÓû§±êʶ¹ØÁª¡£Óû§±êʶ¿Éͨ¹ýÒÔϼ¸·½ÃæÈ·¶¨£º
ASP.NET Forms Éí·ÝÑé֤ϵͳ£¬¸ÃϵͳÔÚÉí·ÝÑéÖ¤³É¹¦Ö®ºóÉèÖÃÓû§±êʶ¡£
Windows »ò Passport Éí·ÝÑéÖ¤£¬´Ë¹¦ÄÜÔÚÉí·ÝÑéÖ¤³É¹¦Ö®ºóÉèÖÃÓû§±êʶ¡£
×Ô¶¨ÒåÉí·ÝÑéÖ¤£¬¶ÔÓû§Æ¾¾ÝµÄ»ñÈ¡ºÍÓû§±êʶµÄÉèÖýøÐÐÊÖ¶¯¹ÜÀí¡£
ASP.NET Forms Éí·ÝÑéÖ¤ÐèÒª´´½¨µÇ¼´°Ìå²¢ÌáʾÓû§Ìṩƾ¾Ý¡£Ê¹Óà ASP.NET µÇ¼¿Ø¼þ£¬ÎÞÐè±àдÈκδúÂë¼´¿É´´½¨µÇ¼´°Ìå²¢Ö´ÐÐ Forms Éí·ÝÑéÖ¤¡£ÓйØʹÓà ASP.NET ¹¦ÄܶÔÓû§½øÐÐÉí·ÝÑéÖ¤µÄÐÅÏ¢£¬Çë²Î¼û ASP.NET µÇ¼¿Ø¼þ¸ÅÊö ºÍ ʹÓóÉÔ±×ʸñ¹ÜÀíÓû§¡£
 
2¡¢ÄäÃûÓû§
ÅäÖÃÎļþ»¹¿ÉÓÉÄäÃûÓû§Ê¹Óá£Ä¬ÈÏÇé¿öÏ£¬²¢²»»áÆôÓÃÄäÃûÅäÖÃÎļþÖ§³Ö£¬Òò´Ë±ØÐëÏÔʽÆôÓᣴËÍ⣬µ±ÔÚ Web.config ÎļþÖж¨ÒåÅäÖÃÎļþÊôÐÔʱ£¬±ØÐ뽫ÆäÏÔʽ¶¨ÒåΪ¿ÉÓÉÄäÃûÓû§µ¥¶ÀʹÓá£ÓÉÓÚÅäÖÃÎļþ¿ÉÄÜÉè¼ÆΪÓÉͨ¹ýÉí·ÝÑéÖ¤µÄÓû§Ê¹Ó㬲¢ÇÒÐí¶àÊôÐÔ¿ÉÄÜ°üº¬ÄäÃûÓû§²»¿ÉÓõĸöÈËÐÅÏ¢£¬Òò´ËĬÈÏÇé¿öÏÂÅäÖÃÎļþÊôÐÔ²¢²»Ö§³ÖÄäÃû·ÃÎÊ¡£
Èç¹ûÆôÓÃÁËÄäÃû±êʶ£¬ÔòÓû§Ê״ηÃÎÊÕ¾µãʱ£¬ASP.NET ½«ÎªÆä´´½¨Ò»¸öΨһ±êʶ¡£¸ÃΨһÓû§±êʶ´æ´¢ÔÚÓû§¼ÆËã»úÉ쵀 Cookie ÖУ¬ÕâÑù£¬¶ÔÓÚÿ¸öÒ³ÇëÇó£¬ÆäÓû§¶¼¿ÉÒԵõ½±êʶ¡£Cookie µÄĬÈÏÓÐЧÆÚÉèÖÃΪ´óÔ¼ 70 Ì죬µ±Óû§·ÃÎÊÕ¾µãʱ»á¶¨ÆÚ¶ÔÆä½øÐиüС£Èç¹ûÓû§µÄ¼ÆËã»ú²»½ÓÊÜ Cookie£¬Ôò¿É½«¸ÃÓû§µÄ±êʶ×÷ΪÇëÇóµÄÒ³ URL µÄÒ»²¿·ÖÀ´Î¬»¤£¨¾¡¹ÜÓû§¹Ø±Õä¯ÀÀÆ÷ʱ¸Ã±êʶ»á¶ªÊ§£©¡£
 
3¡¢Ç¨ÒÆÄäÃûÅäÖÃÎļþÐÅÏ¢
ÔÚÓÐЩÇé¿öÏ£¬ÄúµÄÓ¦ÓóÌÐò×î³õ¿ÉÄÜά»¤×ÅÄäÃûÓû§µÄ¸öÐÔ»¯ÉèÖÃÐÅÏ¢£¬µ«×îºó¸ÃÓû§µÇ¼µ½ÁËÄúµÄÓ¦ÓóÌÐòÖС£ÔÚÕâÖÖÇé¿öÏ£¬¸ÃÓû§µÄ±êʶ»á´Ó·ÖÅäµÄÄäÃûÓû§±êʶ¸ü¸ÄΪÉí·ÝÑéÖ¤½ø³ÌÌṩµÄ±êʶ¡£
µ±Óû§µÇ¼£¨¼´²»ÔÙÊÇÄäÃûÓû§£©Ê±£¬½«Òý·¢ MigrateAnonymous ʼþ¡£Èç¹ûÓбØÒª£¬¿ÉÒÔ¶Ô´Ëʼþ½øÐд¦Àí£¬ÒԱ㽫ÐÅÏ¢´ÓÓû§µÄÄäÃû±êʶǨÒƵ½ÐµÄͨ¹ýÉí·ÝÑéÖ¤µÄ±êʶ¡£ÏÂÃæµÄ´úÂëʾÀýÑÝʾÓû§Í¨¹ýÉí·ÝÑé֤ʱÈçºÎǨÒÆÐÅÏ¢¡£
public void Profile_OnMigrateAnonymous(object sender, ProfileMigrateEventArgs args)
{
 


Ïà¹ØÎĵµ£º

dz̸ASP.net°²È«±à³Ì

ÔÚWeb±à³Ì¹ý³ÌÖУ¬´æÔÚןܶలȫÒþ»¼¡£±ÈÈçÔÚÒÔÇ°µÄASP°æ±¾ÖУ¬CookieΪ·ÃÎÊÕߺͱà³ÌÕ߶¼ÌṩÁË·½±ã£¬²¢Ã»ÓÐÌṩ¼ÓÃܵŦÄÜ¡£´ò¿ªIEä¯ÀÀÆ÷£¬Ñ¡Ôñ“¹¤¾ß”²Ëµ¥ÀïµÄ“InternetÑ¡Ï¬È»ºóÔÚµ¯³öµÄ¶Ô»°¿òÀïµ¥»÷“ÉèÖÔ°´Å¥£¬Ñ¡Ôñ“²é¿´Îļþ”°´Å¥£¬ÔÚµ¯³öµÄ´°¿ÚÖУ¬¾Í»áÏÔʾӲÅÌÀï ......

asp.net¿Í»§¶Ë½Å±¾µ÷ÓÃÒ³Ãæ·½·¨

  µÚÒ»²½£º
½«Ä³¸öÒ³ÃæµÄ·½·¨ ÓÐ webmethod  attribute;
[WebMethod]
//Ö»ÄÜÊÇ public static µÄ·½·¨
public static DateTime GetCurrentTime()
{
return DateTime.UtcNow;
}
µÚ¶þ²½£º
 Ò³ÃæÓÐÒ»¸öScriptManager ÉèÖÃËüµÄenablepagemethod=true;
asp:ScriptManager ID="Scri ......

ASP.netÖеÄAJAXѧϰ¼Ç¼

 ½ñÌìÎÒÖ÷ҪѧϰÁËUpdateModeÊôÐÔ¼°Ê¹ÓÃUpdateTriggers£¬°ÑÊéÖÐËù½ÌÊÚµÄÄÚÈÝÓöà¸öÀý×Óʵ¼ùÁËһϣ¬È·ÊµÃ÷°×ÁËÐí¶à¡£
  UpdateMode
      Ê×ÏÈÔÚÉÏһƪҲÌáµ½¹ýÕâÑùÒ»¸öÀíÂÛ£ºÔÚ̸ÂÛUpdatePanel¿Ø¼þµÄË¢ÐÂʱ£¬µ±UpdatePanel¿Ø¼þÖеÄ×ӿؼþ´¥·¢Async-Postback¶¯×÷ʱ£¬Ë¢ÐµÄÇøÓòÊ ......

ASP.NETÒ³Ãæ¶ÔÏó – User

 »ñÈ¡Óйط¢³öÒ³ÇëÇóµÄÓû§µÄÐÅÏ¢¡£
Ò»¡¢HttpContext Àà
·â×°Óйظö±ð HTTP ÇëÇóµÄËùÓÐ HTTP Ìض¨µÄÐÅÏ¢¡£
HttpContext ÀàÐ͹«¿ªÒÔϳÉÔ±¡£
 ¹¹Ô캯Êý
Ãû³Æ
˵Ã÷
HttpContext
ÒÑÖØÔØ¡£ ³õʼ»¯ LinePragmaCodeInfo ÀàµÄÒ»¸öÐÂʵÀý¡£
 ·½·¨
Ãû³Æ
˵Ã÷
AddError
½«Òì³£Ìí¼Óµ½µ±Ç° HTTP ÇëÇóµÄÒ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ