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

javascript¶íÂÞ˹·½¿é¡¾¸½´øÔ´Âë¡¿

ÔÚ¿´ÁËW3CµÄ¹ØÓÚECMScriptµÄ¶ÔÏ󼰼̳кó£¬ÏÈÊÇÍê³ÉÌ°³ÔÉßµÄʵÏÖ¡£×î½üÓÖ³é¿ÕʵÏÖÁË϶íÂÞ˹·½¿é¡£¶ÔÓÚ¶íÂÞ˹·½¿éÖØÒªµÄ²»ÊÇÓÎÏ·±¾Éí£¬¶øÊÇÔÚÕâ¸ö¹ý³ÌÖжÔÓÚjavascript¼Ì³ÐµÄʹÓá£
µ±È»ÔÚһЩ¶ÔÏóµÄ»®·Ö¼°Ê¹Óùý³Ì»¹´æÔÚ覴ã¬Ëã·¨Ò²²»Ëã×îÓÅ£¬·¢²¼³öÔ´ÂëÖ»ÊÇÏë×ö¸ö½»Á÷¡£ÒÔϾÍÌṩԴ´úÂ빩´ó¼Ò²Î¿¼£¬Ò²Îª×Ô¼º×ö¸ö±¸·Ý¡£Ò²¿ÉÔÚÖ±½Óµã»÷ÏÂÔØ¡£ÓÎϷЧ¹ûͼΪ£º
ÕâÀï¶Ô´úÂë²»×ö˵Ã÷ÁË£¬¿ÉÒÔ¿´´úÂë¿éÖеÄ×¢ÊÍ//********************************Utils.js*******************************************************
/**
* ¸¨ÖúÀà
* @author leeyee
* @blog blog.csdn.net/oxcow
* @email seadlead@gmail.com
* @data 2010-4
*/
/**
* ´´½¨DOMÔªËØ
*
* @param sTagName
* ÔªËØÃû
* @param sTagId
* ÔªËØID
* @param sText
* ÔªËØÎı¾
* @return DOMÔªËضÔÏó
*/
function createElement(sTagName, sTagId, sText) {
var oElement = document.createElement(sTagName);
if (sTagId != null) {
oElement.setAttribute("id", sTagId);
}
if (sText != null) {
oElement.appendChild(document.createTextNode(sText));
}
return oElement;
}
function RandomEventUtils() {
}
/**
* µÃµ½´ÓÁãµ½NµÄËæ»úÕûÊý
*
* @param iN
* ×î´óÕûÊý
* @return 0-iNµÄËæ»úÕûÊý
*/
RandomEventUtils.getIntRandomNumfromZeroToN = function(iN) {
var iR = Math.random() * iN;
return Math.round(iR);// ÉáβȡÊý
};
/**
* »ñȡij¸öÔªËØÔÚÊý×éÖеÄλÖÃ
*
* @param vItem
* Ä¿±êÔªËØ
* @return Ä¿±êÔªËØÔÚÊý×éÖеÄË÷Òý
*/
Array.prototype.indexOf = function(vItem) {
for ( var i = 0; i < this.length; i++) {
if (vItem == this[i]) {
return i;
}
}
return -1;
};
/**
* »ñÈ¡Êý×éµÄ³¤¶È¡£²»°üÀ¨undefinedÔªËØ
*
* @return
*/
Array.prototype._length = function() {
var __len = 0;
for ( var i = 0; i < this.length; i++) {
if (this[i] != undefined) {
__len++;
}
}
return __len;
};
/**
* Çå³ýÊý×éÖеÄundefinedÔªËØ
*
* @return Êý×éÇå³ýºóµÄÊý×飨Êý×鳤¶È¸Ä±ä£©
*/
Array.prototype.cleanUndefinedElement = function() {
for ( var i


Ïà¹ØÎĵµ£º

ÈÏÇåJavaScriptºÍJAVAÈ«¾Ö±äÁ¿ºÍ¾Ö²¿±äÁ¿µÄ×÷ÓÃÓò

ÈÏÇåJavaScriptºÍJAVAÈ«¾Ö±äÁ¿ºÍ¾Ö²¿±äÁ¿µÄ×÷ÓÃÓò
2010Äê2ÔÂ28ÈÕ george ·¢±íÆÀÂÛ ÔĶÁÆÀÂÛ
ͨ¹ýÌÔ±¦ÃæÊÔÌâÀ´ÈÏÇåJavaScriptºÍJAVAÈ«¾Ö±äÁ¿ºÍ¾Ö²¿±äÁ¿µÄ×÷ÓÃÓò
×¢ÒâÁ½ÕßÊÇÓÐÑÏÖØÇø±ðµÄ£¡
var a = 100;
function testResult(){
  var b = 2 * a;
  var a = 200;
  var c = a / 2 ......

JavascriptÀàµÄд·¨

JavascriptÖÐfunction¼´ÎªÀ࣬ÔÚfunctionÄÚ²¿ÓÃthisÉèÖÃÀàµÄpublic³ÉÔ±±äÁ¿Óë·½·¨£¬ÀýÈ磺
function myclass(name){
¡¡¡¡¡¡¡¡var str = "private string";¡¡¡¡¡¡¡¡//private field
¡¡¡¡¡¡¡¡function privatefn(){¡¡¡¡¡¡¡¡¡¡¡¡//private method¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡alert(str);
¡¡¡¡¡¡¡¡};
¡¡¡¡¡¡¡¡this.name = name;
¡¡ ......

javascriptÉè¼Æģʽ֮¡¾µ¥Ìåģʽ¡¿

µ¥Ìåģʽ£¨singleton£©
µ¥ÌåÊÇÔڽű¾¼ÓÔØʱ´´½¨µÄ£¬Äܽ«Ò»ÏµÁÐÓйØÁªµÄ±äÁ¿ºÍ·½·¨×é֯Ϊһ¸öÂß¼­µ¥Ôª£¬Âß¼­µ¥ÔªÀïÃæµÄÄÚÈÝͨ¹ýµ¥Ò»µÄ±äÁ¿½øÐзÃÎÊ£»
Ò»¸öµ¥ÌåÖ÷Òª·ÖΪÈý²¿·Ö
ÓÃÓÚ·ÃÎÊÄÚ²¿ÐÅÏ¢µÄÈë¿Ú±äÁ¿£¨È磺Sky£©
ÊôÐÔ£¨È磺nickName/age/timeInfo£©
·½·¨£¨È磺sayHello£©
»ù±¾½á¹¹
01
var Sky = {
02
 & ......

JavaScript WebÁ÷³Ì¶¨Ò幤¾ß

Submitted by gouki on 2008, December 4, 11:47 PM. Javascript
ÓÃjavascript+vmlÀ´×ö¹¤×÷Á÷£¬È·ÊµÊǵÚÒ»´Î¿´µ½£¬ËùÒÔÎÒÔÚ¿´µ½ÓÐÕâ¸öÐÂÎŵÄʱºò£¬¾Í¾õµÃÌرðµÄ³Ô¾ª¡£µ±ÄêµÄTRS¾ÍÊÇÒòΪÓÐÒ»¸öactivex°æµÄ¹¤×÷Á÷¿Ø¼þµÄCMS£¬µ¼ÖÂËûµÄ¼Û¸ñ·Ç³£µÄ¸ß£¬½ñÌìÄܹ»¿´µ½ÓÐjavascript°æµÄ£¬¾ªÑÈÊÇÄÑÃâµÄ¡£¡£¡£
Ö»ÊDz¢·ÇËùÓеĻúÆ÷¶¼Ö ......

JavaScript¸øURLÖ¸¶¨±àÂë

    <script language="javascript" type="text/javascript">
// <!CDATA[
        function Test()
        {
            document.location.href = 'test. ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ