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

JavaScriptËæ»ú±ä»»±í¸ñ±³¾°

s<!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>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>ÎÞ±êÌâÎĵµ</title>
</head>
<body>
<table id="pic" cellpadding="0" cellspacing="0" border="1" width="991" height="439" bordercolor="red">
<tr>
<td>picture chanage!</td>
</tr>
</table>
¡¡¡¡<Script Language="JavaScript">
window.onload=function()
{
changePicture();
}
function changePicture(){
¡¡¡¡
¡¡¡¡image = new Array(3); //¶¨ÒåimageΪͼƬÊýÁ¿µÄÊý×é
¡¡¡¡
¡¡¡¡image [0] = '1.jpg' //±³¾°Í¼ÏóµÄ·¾¶
¡¡¡¡
¡¡¡¡image [1] = '2.jpg'
¡¡¡¡
¡¡¡¡image [2] = '3.jpg'
¡¡¡¡
¡¡¡¡image [3] = '4.jpg'
¡¡¡¡
¡¡¡¡number = Math.floor(Math.random() * image.length)+1;
¡¡¡¡
¡¡¡¡document.getElementById('pic').background="images/"+number+".jpg";
¡¡¡¡}
¡¡¡¡</Script>
</body>
</html>


Ïà¹ØÎĵµ£º

JavaScript ÅжÏcheckboxÈ¡ÖµÎÊÌâ

Ҫȡʲôֵ£¿
È¡value£ºgetElementById("STB_433").value;
ȡ״̬£¨ÊÇ·ñcheck£©£ºgetElementById("STB_433").checked
È¡ID:getElementById("STB_433").id
...
var checkboxs=document.getElementsByTagName("input");
var i;
for(i=0;i<checkboxs.length;i++)
{
if(checkboxs[i].type=='checkbox')
{ ......

JavaScriptѧϰ——ʼþ

     ÕâÁ½ÌìÉÏÎçÒ»Ö±ÔÚѧϰJavaScript£¬ÓÉÓÚ×ÜÊÇÔÚ¿´£¬Ð§¹û²»ÊǺܴó£¬Ò²ºÃ¾ÃûÓз¢±íÎÄÕÂÁË£¬ËùÒÔΪÁ˸üºÃµÄѧϰ£¬°Ñѧµ½µÄ¶«Î÷¼Ç¼ÏÂÀ´¡£ÎÒѧϰJavaScriptµÄÊéÊÇ¡¶¾«Í¨JavaScript+jQuery¡·£¬Èç¹û´ó¼ÒÓиüºÃµÄÊéÇëÍƼö¡£
Ò». ʼþµÄ¸ÅÄî
     C#ÖÐʼþµÄ¶¨Ò壺ʼþÀàËÆÓÚÒì³££¬Ë ......

JSL (JavaScript Loader)

Do you want an ultra fast web site? Get JSL and optimize your JavaScript loading now!
Imagine there's a 4-lane highway between your web browser and the internet itself. This highway is optimize to let pictures, text, and css fly by. But, when it comes to external scripts, the highway crea ......

JavaScript this ¹Ø¼ü×Ö


thisÊÇJavascriptÓïÑÔµÄÒ»¸ö¹Ø¼ü×Ö¡£
Ëü´ú±íº¯ÊýÔËÐÐʱ£¬×Ô¶¯Éú³ÉµÄÒ»¸öÄÚ²¿¶ÔÏó£¬Ö»ÄÜÔÚº¯ÊýÄÚ²¿Ê¹ÓᣱÈÈ磬
¡¡¡¡function test(){
¡¡¡¡¡¡¡¡this.x = 1;
¡¡¡¡}
Ëæן¯ÊýʹÓó¡ºÏµÄ²»Í¬£¬thisµÄÖµ»á·¢Éú±ä»¯¡£µ«ÊÇÓÐÒ»¸ö×ܵÄÔ­Ôò£¬ÄǾÍÊÇthisÖ¸µÄÊÇ£¬µ÷Óú¯ÊýµÄÄǸö¶ÔÏó¡£
ÏÂÃæ·ÖËÄÖÖÇé¿ö£¬ÏêϸÌÖÂÛthisµÄÓ÷¨¡£
......

javascript ³£¼ûÎÊÌâ


1.javascriptÓëHtmlÖеĵ÷ÓÃÎÊÌâ¡£
ÔÚjavascriptÖÐÒªÏë¸ü¸ÄhtmlÖеÄһЩÊôÐÔÖµ£¬ÌرðÊÇÔÚÒ³ÃæÄÚÈݽ϶àʱ£¬Îñ±ØʹÓÃdocument.getElementById(id)µÄ·½Ê½½øÐУ¬·ñÔòjavascript½«²»Äܸü¸ÄÊôÐÔ£¡
2.DateÀà¡£
ÔÚDateÀàÖеÄgetMonth£¨£©µÈ·½·¨·µ»ØֵΪnumber¡£Òò´Ë¿ÉÒÔʹÓÃÊý×é´æ´¢Ô·ÝÐÅÏ¢Èçmonth£½[“1Ô”£¬&ldq ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ