[תÌû]JavaScript´°Ìå´óС
[תÌû]JavaScript´°Ìå´óС
ÍøÒ³¿É¼ûÇøÓò¿í£ºdocument.body.clientWidth
ÍøÒ³¿É¼ûÇøÓò¸ß£ºdocument.body.clientHeight
ÍøÒ³¿É¼ûÇøÓò¿í£ºdocument.body.offsetWidth (°üÀ¨±ßÏߵĿí)
ÍøÒ³¿É¼ûÇøÓò¸ß£ºdocument.body.offsetHeight (°üÀ¨±ßÏߵĿí)
ÍøÒ³ÕýÎÄÈ«ÎÄ¿í£ºdocument.body.scrollWidth
ÍøÒ³ÕýÎÄÈ«Îĸߣºdocument.body.scrollHeight
ÍøÒ³±»¾íÈ¥µÄ¸ß£ºdocument.body.scrollTop
ÍøÒ³±»¾íÈ¥µÄ×ó£ºdocument.body.scrollLeft
ÍøÒ³ÕýÎIJ¿·ÖÉÏ£ºwindow.screenTop
ÍøÒ³ÕýÎIJ¿·Ö×ó£ºwindow.screenLeft
ÆÁÄ»·Ö±æÂʵĸߣºwindow.screen.height
ÆÁÄ»·Ö±æÂÊµÄ¿í£ºwindow.screen.width
ÆÁÄ»¿ÉÓù¤×÷Çø¸ß¶È£ºwindow.screen.availHeight
ÆÁÄ»¿ÉÓù¤×÷Çø¿í¶È£ºwindow.screen.availWidth
HTML¾«È·¶¨Î»:scrollLeft,scrollWidth,clientWidth,offsetWidth
scrollHeight: »ñÈ¡¶ÔÏóµÄ¹ö¶¯¸ß¶È¡£
scrollLeft:ÉèÖûò»ñȡλÓÚ¶ÔÏó×ó±ß½çºÍ´°¿ÚÖÐÄ¿Ç°¿É¼ûÄÚÈݵÄ×î×ó¶ËÖ®¼äµÄ¾àÀë
scrollTop:ÉèÖûò»ñȡλÓÚ¶ÔÏó×¶ËºÍ´°¿ÚÖпɼûÄÚÈݵÄ×¶ËÖ®¼äµÄ¾àÀë
scrollWidth:»ñÈ¡¶ÔÏóµÄ¹ö¶¯¿í¶È
offsetHeight:»ñÈ¡¶ÔÏóÏà¶ÔÓÚ°æÃæ»òÓɸ¸×ø±ê offsetParent ÊôÐÔÖ¸¶¨µÄ¸¸×ø±êµÄ¸ß¶È
offsetLeft:»ñÈ¡¶ÔÏóÏà¶ÔÓÚ°æÃæ»òÓÉ offsetParent ÊôÐÔÖ¸¶¨µÄ¸¸×ø±êµÄ¼ÆËã×ó²àλÖÃ
offsetTop:»ñÈ¡¶ÔÏóÏà¶ÔÓÚ°æÃæ»òÓÉ offsetTop ÊôÐÔÖ¸¶¨µÄ¸¸×ø±êµÄ¼ÆË㶥¶ËλÖÃ
event.clientX Ïà¶ÔÎĵµµÄˮƽ×ù±ê
event.clientY Ïà¶ÔÎĵµµÄ´¹Ö±×ù±ê
event.offsetX Ïà¶ÔÈÝÆ÷µÄˮƽ×ø±ê
event.offsetY Ïà¶ÔÈÝÆ÷µÄ´¹Ö±×ø±ê
document.documentElement.scrollTop ´¹Ö±·½Ïò¹ö¶¯µÄÖµ
event.clientX+document.documentElement.scrollTop Ïà¶ÔÎĵµµÄˮƽ×ù±ê+´¹Ö±·½Ïò¹ö¶¯µÄÁ¿
---
IE£¬FireFox ²îÒìÈçÏ£º
IE6.0¡¢FF1.06+£º
clientWidth = width + padding
clientHeight = height + padding
offsetWidth = width + padding + border
offsetHeight = height + padding + border
IE5.0/5.5£º
clientWidth = width - border
clientHeight = height - border
offsetWidth = width
offsetHeight = height
(ÐèÒªÌáһϣºCSSÖеÄmarginÊôÐÔ£¬ÓëclientWidth¡¢offsetWidth¡¢clientHeight¡¢offsetHeight¾ùÎÞ¹Ø)
ÍøÒ³¿É¼ûÇøÓò¿í£º document.body.clientWidth
ÍøÒ³¿É¼ûÇøÓò¸ß£º document.body.clientHeight
ÍøÒ³¿É¼ûÇøÓò¿í£º document.body.offsetWidth (°üÀ¨
Ïà¹ØÎĵµ£º
1.°Ñ¶ÔÏóµÄËùÓÐÒýÓö¼ÉèÖÃΪnull£¬¿ÉÒÔÇ¿ÖÆÐԵķϳý¶ÔÏ󣨼´Í¨Öª´æ´¢µ¥ÔªÊÕ¼¯³ÌÐòÏú»Ù¶ÔÏóÀ´ÊÍ·ÅÄڴ棩¡£ÕâÊǸöºÃÏ°¹ß¡£
2.ArrayÀ༴Êý×éÀ࣬¿ÉÒÔÈç϶¨Ò壺
var aColors=new Array();
aColors[0]="blue";
aC ......
N.1 »ù±¾½éÉÜ£º
* showModalDialog() (IE 4+ Ö§³Ö)£¬ÓÃÀ´´´½¨Ò»¸öÏÔʾHTMLÄÚÈݵÄģ̬¶Ô»°¿ò¡£
* showModelessDialog() (IE 5+ Ö§³Ö) £¬ÓÃÀ´´´½¨Ò»¸öÏÔʾHTMLÄÚÈݵķÇģ̬¶Ô»°¿ò¡£
N.2 ʹÓ÷½·¨£º
* vReturnValue = window.showModalDialog(sURL [, vArgument ......
AJAX ÔÚä¯ÀÀÆ÷Óë Web ·þÎñÆ÷Ö®¼äʹÓÃÒì²½Êý¾Ý´«Ê䣨HTTP ÇëÇ󣩣¬ÕâÑù¾Í¿ÉʹÍøÒ³´Ó·þÎñÆ÷ÇëÇóÉÙÁ¿µÄÐÅÏ¢£¬¶ø²»ÊÇÕû¸öÒ³Ãæ¡£
AJAX »ùÓÚ Web ±ê×¼
AJAX »ùÓÚÏÂÁÐ Web ±ê×¼£º
JavaScript
XML
HTML
CSS
ÔÚ AJAX ÖÐʹÓÃµÄ Web ±ê×¼Òѱ»Á¼ºÃ¶¨Ò壬²¢±»ËùÓеÄÖ÷Á÷ä¯ÀÀÆ÷Ö§³Ö¡£AJAX Ó¦ÓóÌÐò¶ÀÁ¢ÓÚä¯ÀÀÆ÷ºÍƽ̨¡£
Deafault. ......
ZendStudioÖа²×°JSEclipse²å¼þ
Help -> Install New SoftWare
Work with: add
name:JSEclipse Location:
http://download.macromedia.com/pub/labs/jseclipse/autoinstall
°²×°Íê³ÉºóÅäÖãº
ÐèÒª¸æËß Eclipse ËüÓÐÒ»¸ö JavaScript ÎļþµÄרÓñà¼Æ÷£¬ÕâÑùËüÓÃÎĽ«²»Ê¹ÓÃͨ±¾±à¼Æ ......