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

ÔÚasp.netÖлسµ´¥·¢Ö¸¶¨°´Å¥µÄʼþ

½ñÌìÔÚ¿ª·¢ÖУ¬Óöµ½ÁËÒ»¸öÎÊÌ⣺
      ÔÚHeaderÖÐÓÐÒ»¸öËÑË÷ÊäÈë¿ò£¬ËÑË÷°´Å¥ÊÇButton¿Ø¼þ£¬ÔÚ“×ÊѶÎÄÕÂËÑË÷”Óû§×Ô¶¨Òå¿Ø¼þÖÐÒ²Óõ½ÁËButton¿Ø¼þ¡£
      ½«½¹µãÍ£ÔÚ“×ÊѶ±êÌâ»òÄÚÈÝ”ÊäÈë¿òÖУ¬»Ø³µ£¬µ«ÊÇÏàÓ¦µÄÊÇHeaderÖÐÊäÈë¿òÄÚÈÝ¡£
Ô­Òò£º»Ø³µÖ´ÐеľÍÊÇÄãÒ³ÃæÉϵĵÚÒ»¸ösubmit   button¡£½â¾ö·½·¨£º£¨ÒÔÏÂÒÔ×ÊѶËÑË÷ÊäÈë¿òΪÀý£©
1¡¢js£º
----------------------------------------------------------------------------
/* »Ø³µºóÖ´Ðа´Å¥ */
function SubmitKeyClick(button){
    if (event.keyCode == 13){       
        event.keyCode = 9;
        event.returnValue = false;
        document.all[button].click();
    }
}
function checkinputbox(){
    var charBag = "[^`~@#$%^&/\'|*]";
    var searchkey = document.getElementById("ArticleSearch1_txtSearchKey");
   
    if (trim(searchkey.value).length == 0 || trim(searchkey.value).length > 30){
        alert("×ÊѶÎÄÕ¹ؼü×Ö²»Äܶ¼Îª¿Õ»ò³¤¶È²»Äܳ¬¹ý¸ö×Ö·û£¡");
        searchkey.focus();
        return false;
    }
   
    if (trim(searchkey.value) != ""){ 
        for (var i = 0; i < searchkey.value.length; i++) {
            var c = searchkey.value.charAt(i);
            if (charBag.indexOf(c) > -1) {
               alert("ËÑË÷×ÊѶÎÄÕ¹ؼü×Ö×Ö·û´®Öк¬ÓзǷ¨×Ö·û(" + c +")£¡");
          &nbs


Ïà¹ØÎĵµ£º

ASP.NET MVC ÈëÃÅ

ÓÐʱºòÄãÏëÔÚµ÷ÓÃaction·½·¨Ö®Ç°»òÕßaction·½·¨Ö®ºó´¦ÀíһЩÂß¼­£¬ÎªÁËÖ§³ÖÕâ¸ö£¬ASP.NET MVCÔÊÐíÄã´´½¨action¹ýÂËÆ÷¡£Action¹ýÂËÆ÷ÊÇ×Ô¶¨ÒåµÄAttributes£¬ÓÃÀ´±ê¼ÇÌí¼ÓAction·½·¨Ö®Ç°»òÕßAction·½·¨Ö®ºóµÄÐÐΪµ½¿ØÖÆÆ÷ÀàÖеÄAction·½·¨ÖС£
һЩ¿ÉÄÜÓõ½Action¹ýÂËÆ÷µÄµØ·½ÓУº
ÈÕÖ¾,Òì³£´¦Àí
Éí·ÝÑéÖ¤ºÍÊÚȨ £­ ÏÞÖ ......

ÔÚASP.NETÖÐʹÓÃGlobal.asaxÎļþ

   Global.asax Îļþ£¬ÓÐʱºò½Ð×ö ASP.NET Ó¦ÓóÌÐòÎļþ£¬ÌṩÁËÒ»ÖÖÔÚÒ»¸öÖÐÐÄλÖÃÏìÓ¦Ó¦ÓóÌÐò¼¶»òÄ£¿é¼¶Ê¼þµÄ·½·¨¡£Äã¿ÉÒÔʹÓÃÕâ¸öÎļþʵÏÖÓ¦ÓóÌÐò°²È«ÐÔÒÔ¼°ÆäËüһЩÈÎÎñ¡£ÏÂÃæÈÃÎÒÃÇÏêϸ¿´Ò»ÏÂÈçºÎÔÚÓ¦ÓóÌÐò¿ª·¢¹¤×÷ÖÐʹÓÃÕâ¸öÎļþ¡£
    ¸ÅÊö
    Global.asax λÓÚÓ¦Óà ......

»ñÈ¡ÓÉASP.NETÉú³ÉµÄ·þÎñÆ÷¿Ø¼þ±êʶ·û

 1
        private void Focus(string sDomID)
        {
            RegScript("focus", "document.getElementById(\"" + sDomID + "\").focus();");
     ......

ASP.NET¹ØÓÚÌõÐÎÂëµÄÉú³ÉÎÊÌâ¼æÍøÒ³´òÓ¡

ÌõÐÎÂëÊÇÆù½ñΪֹ×î¾­¼Ã¡¢ÊµÓõÄÒ»ÖÖ×Ô¶¯Ê¶±ð¼¼Êõ¡£ÌõÐÎÂë¼¼Êõ¾ßÓÐÒÔϼ¸¸ö·½ÃæµÄÓŵã
¡¡¡¡A£®ÊäÈëËٶȿ죺Óë¼üÅÌÊäÈëÏà±È£¬ÌõÐÎÂëÊäÈëµÄËÙ¶ÈÊǼüÅÌÊäÈëµÄ5±¶£¬²¢ÇÒÄÜʵÏÖ“¼´Ê±Êý¾ÝÊäÈ딡£
¡¡¡¡B£®¿É¿¿ÐԸߣº¼üÅÌÊäÈëÊý¾Ý³ö´íÂÊΪÈý°Ù·ÖÖ®Ò»£¬ÀûÓùâѧ×Ö·ûʶ±ð¼¼Êõ³ö´íÂÊΪÍò·ÖÖ®Ò»£¬¶ø²ÉÓÃÌõÐÎÂë¼¼ÊõÎóÂëÂʵ ......

Asp.net³£ÓÃÓï¾ä20Ìõ.//µ¯³ö¶Ô»°¿ò.µã»÷תÏòÖ¸¶¨Ò³Ãæ


1.//µ¯³ö¶Ô»°¿ò.µã»÷תÏòÖ¸¶¨Ò³Ãæ
Response.Write(" <script>window.alrt('¸Ã»áԱûÓÐÌá½»ÉêÇë,ÇëÖØÐÂÌá½»£¡') </script>"); Response.Write(" <script>window.loation='http://www.cnblogs.com/kevin1031" target="_blank">http://www.cnblogs.com/kevin1031' </script>");
2.//µ¯³ö¶Ô»°¿ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ