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

javascript»ñÈ¡ä¯ÀÀÆ÷µÄ¿í¶ÈºÍ¸ß¶È

<script language="JavaScript" type="text/JavaScript">
<!--
        function displayScreenSize()
        {
            var bodyWidth           =document.body.clientWidth;               //ÍøÒ³¿É¼ûÇøÓò¿í
            var bodyHeight          =document.body.clientHeight;              //ÍøÒ³¿É¼ûÇøÓò¸ß
            var bodyWidthWithBorder =document.body.offsetWidth;      //ÍøÒ³¿É¼ûÇøÓò¿í(°üÀ¨±ßÏߵĿí)
            var bodyHeightWithBorder=document.body.offsetHeight;     //ÍøÒ³¿É¼ûÇøÓò¸ß(°üÀ¨±ßÏߵĿí)
            var bodyWidthWithScroll =document.body.scrollWidth;         //ÍøÒ³ÕýÎÄÈ«ÎÄ¿í
            var bodyHeightWithScroll=document.body.scrollHeight;        //ÍøÒ³ÕýÎÄÈ«Îĸߠ
            var bodyTopHeight       =document.body.scrollTop;               //ÍøÒ³±»¾íÈ¥µÄÉϱ߾à
            var bodyLeftWidth       =document.body.scrollLeft;               //ÍøÒ³±»¾íÈ¥µÄ×ó±ß¾à
       


Ïà¹ØÎĵµ£º

javascript È¥µôÊý×éÖÐǰ»òºóÖØ¸´Ïî

ÏÂÃæÁ½¸ö·½·¨ÊµÏÖÁËÊý×éÖÐÈ¥µô Ç°Ãæ »òÕß ºóÃæµÄ ÖØ¸´Ïî
È¥µôÇ°ÃæµÄÖØ¸´Ïî·½·¨ °Ñarray [1, 2, 3, 1, 4, 5]È¥µôÇ°ÃæÖØ¸´Ïî µÃµ½ [2, 3, 1, 4, 5].
function unique(a)
{
var r = new Array();
o:for(var i = 0, n = a.length; i < n; i++) {
for(var x = i + 1 ; x < n; x++)
{
......

Javascript ÕýÔò±í´ïʽʹÓÃÊÖ²á

Javascript ÕýÔò±í´ïʽʹÓÃÊÖ²á
Javascript   2008-10-30 10:15   ÔĶÁ97   ÆÀÂÛ0  
×ֺţº ´ó´ó  ÖÐÖР СС
Ò»£®ÕýÔò±í´ïʽƥÅä³£ÓÃÓï·¨
“+”×Ö·û£º¹æ¶¨±í´ïʽ×Ö·û³öÏÖÒ»´Î»ò¶à´Î¡£
“*”×Ö·û£º¹æ¶¨±í´ïʽ×Ö·û³öÏÖÁã´Î»ò¶à´Î¡£
“? ......

javascript ×Ü½á ¡¶Ò»¡·

1£ºÈ¡µÃ±íµ¥ÖеÄTextBox ÖеÄÊý¾Ý£ºdocument.FormName.TextBox.value;
2:  ¿ØÖÆÔªËصÄÏÖʵºÍÒþ²Ø£ºÓÐvisibility  ºÍ display
Çø±ð£º1£©Ç°ÕßµÄÊôÐÔÖµÓУ¬visible¡¢hidden ¡£
         ºóÕßµÄÊôÐÔÖµÓУºblock ºÍ none£»
      2£©Ç°ÕßËäÈ»Òþ ......

javascriptÔÚ´«µÝurl£¨º¬ÓÐÖÐÎÄ£©Ê±³öÏÖÂÒÂë


´ó¼Ò¿ÉÄܶ¼Óöµ½¹ýÔÚдjavascirpt´úÂëʱ´«µÝÖÐÎÄ£¬ÔÚºǫ́ȡµ½Ê±·¢ÏÖÊÇÂÒÂ룬ÕâÀï°ÑÎÒ½ñÌì×öµÄ·½·¨Ð´³öÀ´£¬Ï£Íû¶Ô´ó¼ÒÒÔºóÓÐÓã¡
·½·¨£¨Ò»£©£º
htmlÒ³Ãæ£º
function testOne() {
   var url = "testOne_test.do?expr="+ÄãºÃ;
   location = encodeURI(url);
}
ºǫ́java´úÂ룺
String expr = ne ......

a href=#Óë a href=javascript:void(0)µÄÇø±ð£¿

      ǰÌì×öµÄÒ³ÃæÊÇÒ»¸öiframeµ¯³ö´°¿Ú£¨ËµÃ÷һϣºÍ¬ÊÂÓÃjs½Å±¾¿ª·¢³öÀ´µÄ£©Àï´¥·¢Ò»¸ö<a>Á´½ÓµÄ°´Å¥¿ÉÔڸô°¿ÚÉϵ¯³öÒ»¸ödivÐü¸¡²ã¡£µ«ÊÇÿ´Îµã»÷£¬divÐü¸¡²ã¾Í×Ô¶¯Î»ÓÚIE´°¿ÚµÄ¶¥¶Ë£¬ÏÂÃæµÄiframe´°¿Ú°üº¬µÄÒ³Ãæ»á×Ô¶¯ÉÏÒÆ£¬Î»ÖôíÂÒÁË¡£
      ͬÊÂ˵Ö÷ÒªÊ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ