ÈçºÎÔÚASP.NetºÍJavaScriptÖд«µÝÊý¾Ý
×î½üÅöµ½Ò»ÎÊÌ⣬ÐèÒªÔÚASP.NetºÍJavaScriptÖд«µÝÊý¾Ý¡£¾ßÌåµÄÐèÇóÊÇÕâÑùµÄ£¬Ò³Ãæpostbackºó½«»áload JS£¬µ«ÊÇÐèÒª¼Çס֮ǰij¸ö״̬£¬Õâ¸ö״̬ÊÇÖ¸JSµÄ״̬£¬Ò²¾ÍÊÇ˵load JSºó£¬»¹Òª¼Çס֮ǰµÄ״̬£¬¶ø²»Êǻص½Ä¬ÈϵÄ״̬¡£
Ò»¿ªÊ¼ÏëÁ˺ܶà°ì·¨£¬µ«¶¼²»³É¹¦£¬ºóÀ´ÎÊÁËÎÊͬÊ£¬·¢ÏÖ¿ÉÒÔͨ¹ýÒþ²ØµÄ±íµ¥ÔªËØÀ´´«µÝÊý¾Ý£¬ËùÒÔÌش˼ǼÏÂÀ´¡£
ǰ̨´úÂ룺
<input type="hidden" id="currentTabIndex" name="currentTabIndex" runat="server" />
<script type="text/javascript" language="javascript">
document.getElementById("<%=currentTabIndex.ClientID %>").value = idArray[idArray.length-1].replace(/[^0-9]/gi,'');
</script>
ºǫ́´úÂ룺
Page.ClientScript.RegisterStartupScript(this.GetType(), "InitAndShowTab", "<script>initTabs('" + TabDivID + "',Array(" + TabLabels + "),document.getElementById(\"" + currentTabIndex.ClientID + "\").value," + Width + "," + Height + ");</script>");
ËäÈ»±È½Ï¼òµ¥£¬µ«ÓÐʱºòÒ»ÏÂ×Ó¾ÍÊÇÏë²»ÆðÀ´µÄ¡£
Ïà¹ØÎĵµ£º
¹Ø¼ü×Ö vbscript,javascript,µ÷ÓÃ
vbscriptºÍjavascript»¥Ïàµ÷Ó÷½·¨
¡¡¡¡ASP¾ß±¸¹ÜÀí²»Í¬ÓïÑԽű¾³ÌÐòµÄÄÜÁ¦£¬Äܹ»×Ô¶¯µ÷ÓúÏÊʵĽű¾ÒýÇæÒÔ½âÊͽű¾´úÂëºÍÖ´ÐÐÄÚÖú¯Êý¡£ASP¿ª·¢»·¾³ÌṩÁËÁ½Öֽű¾ÒýÇ棬¼´VBScript£¨È±Ê¡£©ºÍJScript¡£²»¹ý£¬¿ª·¢Õß² ......
function urlencode( str ) {
// http://kevin.vanzonneveld.net
// + original by: Philip Peterson
// + improved by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
// * example 1: urlencode('Kevin van Zonneveld!');
// * returns 1: 'Kevin+van+Zonneveld%21'
&nb ......
×ֺţº´ó ÖРС
·½·¨Ò»£º×µÄ£¬×îÈÝÒ×Àí½âµÄ£¬ÇÒ¿ÉÒÔËæÒâÉèÖÃÒªÅųýµÄ×Ö·û
<script language="javascript">
function isChinese1(str){
var badChar ="ABCDEFGHIJKLMNOPQRSTUVWXYZ";
badChar += "abcdefghijklmnopqrstuvwxyz";
badChar += "0123456789";
badChar += " "+"¡¡";//°ë½ÇÓëÈ«½Ç¿Õ¸ñ
badChar ......
Ô´´ÓÚ2007Äê12ÔÂ16ÈÕ£¬2009Äê10ÔÂ15ÈÕǨÒÆÖÁ´Ë¡£
JavaScriptͨ¹ýÄÚÖõÄsetTimeoutº¯ÊýÀ´Íê³ÉÒ³ÃæÄڵĶ¨Ê±¼ì²é£¬Ò²ÊǺܾÃÒÔǰдµÄ¶«Î÷ÁË¡£
Ö®ËùÒÔÏëÆðËüÀ´£¬ÊÇÒòΪÔÚºÍÏîÄ¿×éÆäËû³ÉԱ˵¸ÃÊÂÇéµÄʱºò£¬±ðÈ˾¹È»³°Ð¦ÎÒ˵ÊÇÉϸöÊÀ¼ÍµÄ´úÂ룬ÏÖÔÚ¶¼ÓÃWEB2.0ÁË¡£
<script language="JavaScript" type="text ......
replace()×î¼òµ¥µÄËãÊÇÄÜÁ¦¾ÍÊǼòµ¥µÄ×Ö·ûÌæ»»¡£
ʾÀý´úÂëÈçÏ£º
<script language="javascript">
var strM = "javascript is a good script language";
//ÔÚ´ËÎÒÏ뽫×ÖĸaÌæ»»³É×ÖĸA
alert(strM.replace("a","A"));
</script>
ËüÖ»Ìæ»»ÁËÊ××Öĸ¡£µ«Èç ......