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

¡¶ASP.NET MVC ÈëÃÅϵÁн̡̳·Ë÷ÒýÌù

ʲôÊÇMVCģʽ
MVC£¨Model-View-Controller£¬Ä£ÐÍ—ÊÓͼ—¿ØÖÆÆ÷ģʽ£©ÓÃÓÚ±íʾһÖÖÈí¼þ¼Ü¹¹Ä£Ê½¡£Ëü°ÑÈí¼þϵͳ·ÖΪÈý¸ö»ù±¾²¿·Ö£ºÄ£ÐÍ£¨Model£©£¬ÊÓͼ£¨View£©ºÍ¿ØÖÆÆ÷£¨Controller£©¡£
ÄÇôMVCģʽºÍÎÒÃÇÊìϤµÄWebFormģʽÓÐʲô²»Í¬ÄØ£¿ËûµÄ¸÷¸ö²¿·ÖÓÖÊÇÔõÑù·Ö¹¤µÄÄØ£¿
ÎÒÃÇÏÈÀ´¿´Ò»ÏÂÆÕͨµÄWebFormģʽÏ£¬ÎÒÃÇÇëÇóÒ»¸öÀýÈçhttp://www.51mvc.com/blog/index.aspxµÄURL£¬ÄÇôÎÒÃǵÄWebForm³ÌÐò»áµ½ÍøÕ¾¸ùĿ¼ÏÂȥѰÕÒblogĿ¼ÏµÄindex.aspxÎļþ£¬È»ºóÓÉindex.aspxÒ³ÃæµÄCodeBehindÎļþ(.CSÎļþ)½øÐÐÂß¼­´¦Àí£¬ÆäÖлòÐíÒ²°üÀ¨µ½Êý¾Ý¿âȥȡ³öÊý¾Ý(ÆäÖеľ­¹ýÔõÑùµÄBLLµ½DALÕâÀï¾Í²»Ì¸ÁË)£¬È»ºóÔÙÓÉindex.aspxÒ³ÃæÀ´³ÊÏÖ¸øÓû§¡£¼òµ¥µÄʾÒâͼÈçÏÂËùʾ£º

Ò²¾ÍÊÇÒ»¸öURLÇëÇóµÄÊÇÔÚ·þÎñÆ÷Óë¸ÃURL¶ÔӦ·¾¶ÉϵÄÎïÀíÎļþ(ASPXÎļþ»òÆäËû)£¬È»ºóÓɸÃÎļþÀ´´¦ÀíÕâ¸öÇëÇó²¢·µ»Ø½á¹û¸ø¿Í»§¶Ë¡£
µ«ÊÇ£¬¶ÔÓÚMVCģʽ£¬ÕâÊÇÔõÑùµÄÒ»¸ö¹ý³ÌÄØ£¿
ÎÒÃÇÏÈÀ´½¨Ò»¸öASP.NET MVCµÄÏîÄ¿°É¡£VS2008ĬÈÏÊÇûÓÐASP.NET MVCµÄÏîÄ¿Ä£°åµÄ£¬Ê×ÏÈÎÒÃÇÐèÒªµ½http://www.microsoft.com/downloads/details.aspx?FamilyId=A24D1E00-CD35-4F66-BAA0-2362BDDE0766&displaylang=enÈ¥ÏÂÔØ×îеÄASP.NET MVCµÄ°²×°³ÌÐò£¬Ä¿Ç°×îа汾µÄMicrosoft ASP.NET MVC Beta(10/15/2008)¡£ÏÂÔØ°²×°Íêºó£¬ÎÒÃÇ¿ÉÒÔÔÚн¨ÏîÄ¿ÄÇÀïÕÒµ½ASP.NET MVCµÄÏîÄ¿£º
 
×¢£ºÈç¹ûÄãµÄÊÇÖÐÎÄ°æµÄVS£¬°²×°Íêºó¿ÉÄÜ»á³öÏÖÕÒ²»µ½Õâ¸öÄ£°åµÄÏÖÏó£¬Äã¿ÉÒԲο¼ÔÚÖÐÎÄ°æVS 08Öа²×°MVCÕâƪÎÄÕÂÉèÖÃһϡ£
½¨Á¢Ò»¸öASP.NET MVCÏîÄ¿ºó£¬Ä¬ÈϵÄÏîÄ¿´ó¸ÅÈçÏÂͼ£º

ÎÒÃÇ¿ÉÒÔ¿´µ½ÏîÄ¿ÖÐÓм¸¸öÎļþ¼ÐµÄÃüÃûºÍMVC£¨Model-View-Controller£¬Ä£ÐÍ—ÊÓͼ—¿ØÖÆÆ÷ģʽ£©ÊǶÔÓ¦µÄ¡£È»ºóÎÒÃÇÔËÐÐÒ»ÏÂÏîÄ¿¿´¿´£º

ÎÒÃÇ×¢Òâµ½µØÖ·À¸µÄURLÊÇ Home/Index,Èç¹û°´ÕÕÎÒÃÇÇ°Ãæ˵µÄWebFormµÄģʽµÄ»°£¬ÎÒÃÇÓ¦¸Ã¿ÉÒÔÔÚÎÒÃǵÄÏîÄ¿µÄ¸ùĿ¼ÏÂÕÒµ½HomeĿ¼£¬È»ºóHomeĿ¼ÏÂÓиöIndexµÄÎļþ£¬µ«ÊÇÎÒÃDz¢²»ÄÜÔÚ¸ùĿ¼ÏÂÕÒµ½HomeÕâ¸öĿ¼¡£²»¹ý»¹ÊÇÈÃÎÒÃÇÔÚViewsĿ¼ÏÂÕÒµ½ÁËViews/Home/Index.aspxÎļþ£¬ÎÒÃÇÊäÈëÕâ¸öµØÖ·ÔËÐп´¿´£º

Oh£¬No£¡Â·¾¶ÊǶԵģ¬ÎļþÒ²´æÔÚ£¬µ«ÎªÊ²Ã´»áÊÇ404,˵ÕÒ²»µ½ÎļþÄØ£¿Èç¹û²»ÊÇÖ±½Ó·ÃÎÊ´æÔÚµÄÎïÀíÎļþ£¬ÄÇôMVCÓÖÊÇÔõÑù¹¤×÷µÄÄØ£¿
Ô­À´°¡£¬MVCģʽµÄ¹¤×÷¹ý³ÌÊÇÕâÑùµÄ£º

ÔÚMVCÖУ¬¿Í»§¶ËµÄËùÇëÇóµÄURLÊDZ»Ó³Éäµ½ÏàÓ¦µÄControllerÈ¥£¬È»ºóÓÉControllerÀ´´¦ÀíÒµÎñÂß¼­


Ïà¹ØÎĵµ£º

asp.net×Ô¶¯Ö´ÐÐÈÎÎñ

ÔÚ¸´ÔÓµÄÒµÎñÓ¦ÓóÌÐòÖУ¬ÓÐʱºò»áÒªÇóÒ»¸ö»òÕ߶à¸öÈÎÎñÔÚÒ»¶¨µÄʱ¼ä»òÕßÒ»¶¨µÄʱ¼ä¼ä¸ôÄڼƻ®½øÐУ¬±ÈÈ綨ʱ±¸·Ý»òͬ²½Êý¾Ý¿â£¬¶¨Ê±·¢Ë͵ç×ÓÓʼþ£¬¶¨ÆÚ´¦ÀíÓû§×´Ì¬ÐÅÏ¢£¬Ö§¸¶ÏµÍ³Öж¨ÆÚͬ²½Òì³£Õ˵¥µÈµÈ£¬ÎÒÃdzÆ֮Ϊ¼Æ»®ÈÎÎñ¡£ÊµÏּƻ®ÈÎÎñµÄ·½·¨Ò²Óкܶ࣬¿ÉÒÔ²ÉÓÃSQLAgentÖ´Ðд洢¹ý³Ì£¬²ÉÓÃWindowsÈÎÎñµ÷¶È³ÌÐòÀ´ÊµÏÖ£ ......

Asp.net MVC²¢²»½ö½öÖ»ÊÇLinq to SQL

    ºÜ¶àAsp.netµÄ½Ì³ÌÖеÄʾÀý´úÂëʹÓõÄÊý¾Ý·ÃÎÊ·½·¨ÊÇLinq to Sql»òÊÇEntity Framework¡£ÎÒÔÚwww.asp.netµÄÂÛ̳ÉÏ¿´µ½ºÜ¶à¹ØÓÚÌÖÂÛÊÇ·ñÓÐÆäËûÌæ´úµÄÊý¾Ý¿â·ÃÎÊ·½Ê½£¬»Ø´ðÊÇ£ºµ±È»ÓС£ÕâƪÎÄÕ¾ͽ²ÊöÁËʹÓÃAdo.Net×÷ΪÊý¾Ý·ÃÎʲãÀ´ÊµÏÖÒ»¸öµäÐ͵ÄÔöɾ²é¸Ä³ÌÐò¡£
    ÓÉÓÚÊÇÒÔÁ·Ï°×÷ΪĿµÄ ......

ASP.NETÓ¦ÓóÌÐòÁ¬½ÓOracleµÄÎÊÌâ

ÔÙWindows XPÉÏдºÃµÄASP.NETÓ¦ÓóÌÐò²¿Êðµ½IISÉÏ,Á¬½Ó²»ÉÏOracle10gÊý¾Ý¿â,Ìáʾ£º
System.Data.OracleClient Requires oracle client software version 8.1.7 or greater¡£
ÒòΪÔÚµ÷ÊÔ»·¾³ÊÇ¿ÉÒÔÁ¬½ÓÉϵÄ,ËùÒÔ¿¼ÂÇ¿ÉÄÜÊÇIISȨÏÞÉèÖÃÎÊÌâ¡£
ÊÔ׎«ASP.NETÓû§Ìí¼Óµ½ÁËAdministrator×éÖС£½á¹ûÁ¬½Ó³É¹¦¡£ ......

asp.net(c#)ÍøÒ³ÌøתÆßÖÖ·½·¨Ð¡½á

asp.net(c#)ÍøÒ³ÌøתÆßÖÖ·½·¨Ð¡½á
·¢²¼Ê±¼ä£º2009-11-25 11:13:03
¡¡¡¡1.Response.Redirect("http://www.yayiba.com",false);
¡¡¡¡Ä¿±êÒ³ÃæºÍÔ­Ò³Ãæ¿ÉÒÔÔÚ2¸ö·þÎñÆ÷ÉÏ£¬¿ÉÊäÈëÍøÖ·»òÏà¶Ô·¾¶¡£ºóÃæµÄboolֵΪÊÇ·ñÍ£Ö¹Ö´Ðе±Ç°Ò³¡£
ÌøתÏòеÄÒ³Ã棬ԭ´°¿Ú±»´úÌæ¡£"
ä¯ÀÀÆ÷ÖеÄURLΪз¾¶¡£
:Response.Redirect·½ ......

¾­µäµÄAsp.netÈý²ãÉè¼Æ

Èý²ãµÄ»®·Ö:
        Ä¿µÄ£º¸ßÄÚ¾Û£¬µÍñîºÏ£¬Îª¸üºÃµÄʵÏÖ·Ö²¼Ê½¿ª·¢ºÍά»¤¡£
        Óû§½çÃæ²ã: Ò³Ãæ,Óû§¿Ø¼þ,ͼƬ£¬Ñùʽ±í
        ÒµÎñÂß¼­²ã:ÒµÎñ½Ó¿Ú( BusinessInterface ), ÒµÎñʵÌå( BusinessEntity),ÒµÎñÂß¼­(BusinessLogic)
    ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ