ASP.NET MVC¼°IIS6.0ÅäÖÃ×ܽá
1. config½á¹¹
Framework\Config\Machine.config, ΪËùÓÐconfigµÄ¸ù£¬ÌرðÖ»ÓÐËü²ÅÄܾßÓÐ<processMode>½Ú£¬¸Ã½ÚÐ޸ĺó±ØÐëÖØÆôIIS·½ÄÜÉúЧ£¬¶øÆäËü½ÚµÄ¸Ä¶¯£¬Ö»ÒªÒ»±£´æ£¬¾ÍÓÐЧÁË£¬ÕâÊÇIIS6µÄÒ»´ó½ø²½¡£
ÒÔÏ·ֱðÊÇ´ÓÉÏÍùÏµļ¸¸ö¼Ò×åÀࣨΪ¼Ì³Ð¹ØÏµ£¬ÕâÖÖÉè¼Æ¿ÉÒÔ´óÁ¿¼õÉÙÖØ¸´´úÂ룩
Frameework\Config\Web.config
ÍøÕ¾µÄWeb.config
ÐéÄâĿ¼µÄWeb.config
¸÷¼¶×ÓĿ¼µÄWeb.config
<location path='some path' />¿ÉÒÔÖ±½Ó·ÃÎÊÕâ¸ö¼Ò×åÊ÷ÉϵÄÈÎÒâÒ»¸öWeb.config
2.³£ÓÃsectionºÍsectionGroup, ¿É²Î¼ûmsdn
<system.Web>
<httpModules>
<add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add name="UrlRoutingModule" type="System.Web.Routing.UrlRoutingModule, System.Web.Routing, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
</httpModules> ¾ÍÊÇÀ´¶¨ÒåMVC, ÆäʵÕâÖÖÉè¼Æ£¬ÒѾÓÐAOPµÄ˼ÏëÁË
3.×Ô¶¨ÒåÅäÖÃ
<configSections>
<sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
Ïà¹ØÎĵµ£º
//ƽ³£µ÷ÓÃjavascript·½·¨
ClientScript.RegisterStartupScript(this.GetType(), "", "<script>alert'Weclome!!!');</script>");
±³¾°²»Îª°×É«µÄ·½·¨£º
Page.ClientScript.RegisterStartupScript(Page.GetType(), "message", "<script language='javascript' defer>alert('Ìí¼Óʧ°Ü£¬ÇëÁªÏµ¼¼ÊõÔ±£¡') ......
ÔÚ²»Í¬°æ±¾µÄ IIS ÉÏʹÓà ASP.NET MVC
ASP.NET MVC Framework ÒÀÀµÓÚ URL ·ÓÉ¡£ÎªÁËÀûÓà URL ·ÓÉ£¬¿ÉÄܲ»µÃ²»ÔÚ Web ·þÎñÆ÷ÉÏÖ´ÐжîÍâµÄÅäÖò½Öè¡£ÕâЩ²½ÖèÈ¡¾öÓÚ Internet Information Services (IIS) µÄ°æ±¾ºÍÓ¦ÓóÌÐòµÄÇëÇó´¦Àíģʽ¡£
IIS µÄ×îа汾Êǰ汾 7.0¡£IIS µÄ´Ë°æ±¾°üÀ¨ÔÚ Windows Server 2008 ÖС£»¹¿ÉÒÔ ......
ÏÖÔ򵀮óÒµ¼¶¿ª·¢ÏîÄ¿£¬ÌرðÊÇÍøÕ¾Ò»°ã¶¼»áÓõ½log¹¦ÄÜ£¬ÏëÏë´ó²¿·Ö»áÓÃEnterprise Logging Application Block µÄ¹¦ÄÜ »òÕß×Ô¼ºÐ´Ò»¸ö×é¼þ£¬¼Ç¼ϵͳÈÕ־ʼþ£¬¸üºÃµÄ¸ú×ÙÁ˽âϵͳÔËÐÐÇé¿ö, ÏÖÓÃASP.NET MVC µÄ¹ýÂËÊôÐÔʵÏÖlog¹¦ÄÜ£¡
ASP.NET MVCµÄfilter ÊÇÒ»¸öÊôÐÔ£¬¿ÉÒÔÓ¦Ó ......
System.Drawing.Image watermark = System.Drawing.Image.fromFile(Server.MapPath("watermark.gif"));
Bitmap srcImg = new Bitmap(Server.MapPath("example.jpg"));
Graphics graphics = Graphics.fromImage(srcImg);
graphics.DrawImage(watermark,
srcImg.Width - watermark.Width,
srcImg.Height - w ......
<HTML><HEAD><TITLE>WMI Scripting HTML</TITLE>
<META http-equiv=Content-Type c>
<SCRIPT language=JScript event="OnCompleted(hResult,pErrorObject, pAsyncContext)" for=foo>
var MACaddress=unescape(MACAddr);
alert(MACaddress);
document.forms[0].txtMACAddr.value=u ......