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

JavaScript:history.go() µÄÃîÓÃ(ת)

  ÔÚWeb¿ª·¢ÖУ¬»áÓöµ½´ÓÒ»Ò³£¨¸¸Ò³£©µ¼ÏòÁíÒ»Ò³£¨×ÓÒ³£©£¬²¢ÇÒÒªÇó“·µ»Ø”¸¸Ò³µÄÇé¿ö£¬ÔÚÕâÀïÈç¹ûÓÃASP.NETÌṩµÄ Response.Redirect()·½·¨£¬ÍùÍù²»»á´ïµ½ÀíÏëµÄЧ¹û£¬ÀýÈ磺·µ»Øºó£¬ÖØмÓÔØÁËÒ³Ã棬ÎÞ·¨±£´æµ¼Ïò×ÓҳǰµÄ״̬£¬µÈµÈ£¬ÔÚÕâÀïÎҾͽéÉÜ Ò»ÏÂÈçºÎʹÓÃJavaScriptÖÐhistory.go()º¯ÊýÀ´ÊµÏÖ·µ»Ø¹¦Äܲ¢ÇÒ±£´æס״̬µÄ·½·¨¡£
     Õâ¸öº¯ÊýÓÃÆðÀ´ºÜ¼òµ¥£¬Ö»ÒªÔÚÒ³ÃæÉϼÓÒ»¸öhtmlµÄinputÔªËØ£¬ÀýÈ磺
     <input type="button" value="·µ»Ø">
     È»ºóÔÙΪÕâ¸öÔªËØÌí¼ÓonclickÊôÐÔ£¬È磺
     <input type="button" value="·µ»Ø" onclick="history.go(-1);">
     ÕâÑù¾ÍÄÜ´ïµ½·µ»ØÉÏÒ»Ò³µÄЧ¹û¡£µ«ÊÇ£¬ÍùÍùÔÚʵ¼ùÖУ¬²¢Ã»ÓÐÕâô¼òµ¥£¬µ±ÄãÔÚÏò·þÎñÆ÷Ìá½»ÇëÇóµÄʱºò£¬ÒýÆðÒ³Ãæ»Ø·¢£¬ÄãÔÙÓÃhistory.go(-1) ÕâÕоͲ»ÁéÀ²£¬ËüÔÚÕâÀïÊÇ·µ»ØÄã»Ø·¢Ç°µÄ״̬£¬goºóÃæµÄ²ÎÊý£¬Êµ¼ÊÉϾÍÊDZêʶÄãÒª·µ»ØÄã»Ø·¢µÚÇ°n´ÎµÄ״̬£¬ËùÒÔÖ»ÒªÄܼÇס»Ø·¢Á˼¸´Î£¬¾ÍÄÜÓà history.go(-n)׼ȷµØ·µ»Øµ½¸¸Ò³ÁË¡£
     ÔÚWeb¿ª·¢ÖУ¬È«¾Ö±äÁ¿Ò²ÊǴ治סµÄ£¬µ±Ò³Ãæ»Ø·¢ºó£¬È«¾Ö±äÁ¿µÄÖµ¾Í»á¶ªÊ§£¬È¡¶ø´úÖ®µÄÊÇÊÓͼ״̬£¬ËùÒÔÎÒÃǾÍÖ»ÄÜÓÃÊÓͼ״̬À´¼Ç¼»Ø·¢µÄ´ÎÊýÁË¡£ÄÇô¾Í·â×°Ò»¸öÊÓͼ״̬ÊôÐÔ°Ñ¡£
     public int returnCount
     {
         get{
               if(ViewState["returnCount"] == null)
                   ViewState["returnCount"] = 0;
               return   (int)ViewState["returnCount"];
         }
         set { ViewState["returnCount"] = value ;}
     }
     ¶¨ÒåºÃÕâ¸öºó£¬°ÑËû·Åµ½Page_LoadÀïÃ棬ÈÃËûÿ´ÎÔÚÒ³Ãæ»Ø·¢Ê±¼õ1£¬ÕâÑù¾ÍÄÜ׼ȷµÄ¼Çס»Ø·¢Á˼¸´Î¡£


Ïà¹ØÎĵµ£º

JavaScriptºÜƯÁÁµÄÈÕÀúÌØЧ

<!doctype html public "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" /> ......

javascript»ñÈ¡µ±Ç°µçÄÔ²Ù×÷ϵͳµÄÎļþ·¾¶µÄ·½Ê½

<script language="javascript" type=text/javascript>
var fso;
fso = new ActiveXObject("Scripting.FileSystemObject");
function SystemSpecialFolder(Special)
{
   var tfolder,  TemporaryFolder = Special;//0: Windows ²Ù×÷ϵͳ°²×°µÄÎļþ;1:°üº¬¿â¡¢×ÖÌ壬ÒÔ¼°É豸Çý¶¯³ÌÐòµÄ System Î ......

JavaScriptʵÏÖÒ³Ãæ´«Öµ

ÎÒ»¹ÊDzËÄñ£¬Çë´ó¼Ò¶àÖ¸½Ì£¡
Ò³ÃæÒ»£º
<html>
 <head>
  <title> Ò³Ãæ´«ÖµÒ» </title>
  <script>
    function funShow()
 {
    var arr=new Array(6);
       var arrs = showModalDialog("Ò³ ......

JavaScript ÖÆ×÷¼òµ¥¼ÆËãÆ÷ isNaN eval ʹÓÃ

Åжϣ¨value£©ÊÇ·ñÊÇÒ»¸öÊý×Ö£¬¼ÙÈçÖµÊÇNaNÄÇôIsNan·µ»ØTRUE£¬·ñÔò·µ»ØFALSE¡£
»¹ÓÐÒ»ÖÖ°ì·¨£¬±äÁ¿¿ÉÒÔÓëËü×ÔÉí½øÐбȽϡ£ ¼ÙÈç±È½ÏµÄ½á¹û²»µÈ£¬ÄÇôËü¾ÍÊÇ NaN ¡£
ÕâÊÇÒòΪ NaN ÊÇΨһÓë×ÔÉí²»µÈµÄÖµ¡£
µÚÒ»ÖÖ·½·¨£º
<html>
<head>
<title>¼òµ¥¼ÆËãÆ÷µÄÖÆ×÷</title>
</ ......

JavascriptÃæÏò¶ÔÏó±à³Ì£¨¶þ£©£º¼Ì³Ð


ZT:http://www.ruanyifeng.com/blog/2010/05/object-oriented_javascript_inheritance.html
ÉÏÒ»´ÎµÄÎÄÕ£¬Ö÷Òª½éÉÜÁËÈçºÎ"·â×°"Êý¾ÝºÍ·½·¨£¬´ÓÔ­ÐͶÔÏóÉú³ÉʵÀý¡£
½ñÌìÒª½éÉܵÄÊÇ£¬¶à¸öÔ­ÐͶÔÏóÖ®¼äÈçºÎ"¼Ì³Ð"¡£
±ÈÈ磬ÏÖÔÚÓÐÒ»¸ö"¶¯Îï"¶ÔÏó£¬
¡¡¡¡function Animal(){
¡¡¡¡¡¡¡¡this.species = "¶¯Îï";
¡¡¡¡}
»¹ÓÐ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ