javascript ¸÷Öֵõ½ä¯ÀÀÆ÷¿í¶ÈºÍ¸ß¶ÈµÄº¯Êý
function getInfo()
{
var s = "";
s += " ÍøÒ³¿É¼ûÇøÓò¿í£º"+ document.body.clientWidth+"\n";
s += " ÍøÒ³¿É¼ûÇøÓò¸ß£º"+ document.body.clientHeight+"\n";
s += " ÍøÒ³¿É¼ûÇøÓò¿í£º"+ document.body.offsetWidth + " (°üÀ¨±ßÏߺ͹ö¶¯ÌõµÄ¿í)"+"\n";
s += " ÍøÒ³¿É¼ûÇøÓò¸ß£º"+ document.body.offsetHeight + " (°üÀ¨±ßÏߵĿí)"+"\n";
s += " ÍøÒ³ÕýÎÄÈ«ÎÄ¿í£º"+ document.body.scrollWidth+"\n";
s += " ÍøÒ³ÕýÎÄÈ«Îĸߣº"+ document.body.scrollHeight+"\n";
s += " ÍøÒ³±»¾íÈ¥µÄ¸ß(ff)£º"+ document.body.scrollTop+"\n";
s += " ÍøÒ³±»¾íÈ¥µÄ¸ß(ie)£º"+ document.documentElement.scrollTop+"\n";
s += " ÍøÒ³±»¾íÈ¥µÄ×ó£º"+ document.body.scrollLeft+"\n";
s += " ÍøÒ³ÕýÎIJ¿·ÖÉÏ£º"+ window.screenTop+"\n";
s += " ÍøÒ³ÕýÎIJ¿·Ö×ó£º"+ window.screenLeft+"\n";
s += " ÆÁÄ»·Ö±æÂʵĸߣº"+ window.screen.height+"\n";
s += " ÆÁÄ»·Ö±æÂÊµÄ¿í£º"+ window.screen.width+"\n";
s += " ÆÁÄ»¿ÉÓù¤×÷Çø¸ß¶È£º"+ window.screen.availHeight+"\n";
s += " ÆÁÄ»¿ÉÓù¤×÷Çø¿í¶È£º"+ window.screen.availWidth+"\n";
s += " ÄãµÄÆÁÄ»ÉèÖÃÊÇ "+ window.screen.colorDepth +" λ²ÊÉ«"+"\n";
s += " ÄãµÄÆÁÄ»ÉèÖà "+ window.screen.deviceXDPI +" ÏñËØ/Ó¢´ç"+"\n";
s += " windowµÄÒ³Ãæ¿ÉÊÓ²¿·Öʵ¼Ê¸ß¶È(ff) "+window.innerHeight+"\n"; &nbs
Ïà¹ØÎĵµ£º
<SCRIPT LANGUAGE="javascript">
<!--
window.open ('page.html', 'newwindow', 'height=100, width=400, top=0,left=0, toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no')
file://д/³ÉÒ»ÐÐ
-->
</SCRIPT>
²ÎÊý½âÊÍ£º
<SCRIPT LANGUAGE="javascript"&g ......
Èç¹û¶ÔjavascriptÁ˽ⲻÊÇÌØ±ðÉîÈëµÄ»°,ºÜÈÝÒ׾ͻáд³ö²»¼æÈݵĴúÂë(¾ÍÏñÎÒ),Õâʱºò¾ÍµÃÅжÏä¯ÀÀÆ÷ÁË¡£±ÈÈçʼþÕìÌý¡¢Ò»Ð©Êó±êºÍ¼üÅÌʼþ¡¢RangeµÈ,һЩ¶¼»á²»Ò»Ñù.ÏÂÃæÁгö¼¸ÖÖ³£Óõļì²âä¯ÀÀÆ÷·½·¨£¬ÒÔ÷ϹÛÖÚ!
¶ÔÏó/ÌØÕ÷¼ì²â·¨
¸Ã·½·¨ÊÇÒ»ÖÖÅжÏä¯ÀÀÆ÷ÄÜÁ¦£¨¶ø·Çä¯ÀÀÆ÷µÄÈ·ÇÐÐͺţ©µÄͨÓ÷½·¨¡£´ó²¿·ÖJSר¼ÒÈÏΪÕâ¸ö·½· ......
[ 2007-8-6 17:03:00 | By: ibrahim ]
javascript²Ù×÷Select±ê¼ÇÖÐoptions¼¯ºÏ
ÏÈÀ´¿´¿´options¼¯ºÏµÄÕ⼸¸ö·½·¨£º
options.add(option)·½·¨Ïò¼¯ºÏÀïÌí¼ÓÒ»Ïîoption¶ÔÏó£»
options.remove(index)·½·¨ÒƳýoptions¼¯ºÏÖеÄÖ¸¶¨Ï
options(index)»òoptions.item(index)¿ÉÒÔͨ¹ýË÷Òý»ñÈ¡options¼¯º ......
Õâ¸öÎÊÌâºÜ¼òµ¥£¬Ö÷ÒªÓÐÏÂÃæ¼¸¸ö֪ʶµã£º
£¨1£© È¡µÃʱ¼ä£ºvar d=new Date();var time=d.toLocaleString()
£¨2£© ÏÔʾÔÚÍøÒ³ÉÏ£¬¼ÙÉèдÔÚÒ»¸ö<span>ÖУ¬ÇÒ¸Ã<span>µÄidΪshowTime:
document.getElementById("showTime").innerHTML ......