javascriptÍøÒ³¶Ô»°¿ò²ÎÊýÏê½â
N.1 »ù±¾½éÉÜ£º
* showModalDialog() (IE 4+ Ö§³Ö)£¬ÓÃÀ´´´½¨Ò»¸öÏÔʾHTMLÄÚÈݵÄģ̬¶Ô»°¿ò¡£
* showModelessDialog() (IE 5+ Ö§³Ö) £¬ÓÃÀ´´´½¨Ò»¸öÏÔʾHTMLÄÚÈݵķÇģ̬¶Ô»°¿ò¡£
N.2 ʹÓ÷½·¨£º
* vReturnValue = window.showModalDialog(sURL [, vArguments] [,sFeatures])
* vReturnValue = window.showModelessDialog(sURL [, vArguments] [,sFeatures])
N.2.1 ²ÎÊý˵Ã÷£º
* sURL-- ±ØÑ¡²ÎÊý£¬ÀàÐÍ£º×Ö·û´®¡£ÓÃÀ´Ö¸¶¨¶Ô»°¿òÒªÏÔʾµÄÎĵµµÄURL¡£
* vArguments-- ¿ÉÑ¡²ÎÊý£¬ÀàÐÍ£º±äÌå¡£ÓÃÀ´Ïò¶Ô»°¿ò´«µÝ²ÎÊý¡£´«µÝµÄ²ÎÊýÀàÐͲ»ÏÞ£¬°üÀ¨Êý×éµÈ¡£¶Ô»°¿òͨ¹ýwindow.dialogArgumentsÀ´È¡µÃ´«µÝ½øÀ´µÄ²ÎÊý¡£
* sFeatures-- ¿ÉÑ¡²ÎÊý£¬ÀàÐÍ£º×Ö·û´®¡£ÓÃÀ´ÃèÊö¶Ô»°¿òµÄÍâ¹ÛµÈÐÅÏ¢£¬¿ÉÒÔʹÓÃÒÔϵÄÒ»¸ö»ò¼¸¸ö£¬Ó÷ֺœ;”¸ô¿ª¡£
1. dialogHeight :¶Ô»°¿ò¸ß¶È£¬²»Ð¡ÓÚ£±£°£°px£¬£É£Å£´ÖÐdialogHeight ºÍ dialogWidth ĬÈϵĵ¥Î»ÊÇem£¬¶ø£É£Å£µÖÐÊÇpx£¬Îª·½±ãÆä¼û£¬ÔÚ¶¨Òåmodal·½Ê½µÄ¶Ô»°¿òʱ£¬ÓÃpx×öµ¥Î»¡£
2. dialogWidth: ¶Ô»°¿ò¿í¶È¡£
3. dialogLeft: ÀëÆÁÄ»×óµÄ¾àÀë¡£
4. dialogTop: ÀëÆÁÄ»ÉϵľàÀë¡£
5. center: {yes | no | 1 | 0 }£º´°¿ÚÊÇ·ñ¾ÓÖУ¬Ä¬ÈÏyes£¬µ«ÈÔ¿ÉÒÔÖ¸¶¨¸ß¶ÈºÍ¿í¶È¡£
6. help: {yes | no | 1 | 0 }£ºÊÇ·ñÏÔʾ°ïÖú°´Å¥£¬Ä¬ÈÏyes¡£
7. resizable: {yes | no | 1 | 0 } £Û£É£Å£µ£«£Ý£ºÊÇ·ñ¿É±»¸Ä±ä´óС¡£Ä¬ÈÏno¡£
8. status: {yes | no | 1 | 0 } £ÛIE5+£Ý£ºÊÇ·ñÏÔʾ״̬À¸¡£Ä¬ÈÏΪyes[ Modeless]»òno[Modal]¡£
9. scroll:{ yes | no | 1 | 0 | on | off }£ºÖ¸Ã÷¶Ô»°¿òÊÇ·ñÏÔʾ¹ö¶¯Ìõ¡£Ä¬ÈÏΪyes¡£
10. ÏÂÃ漸¸öÊôÐÔÊÇÓÃÔÚHTAÖеģ¬ÔÚÒ»°ãµ
Ïà¹ØÎĵµ£º
Chrome ÓµÓиü¿ìËÙµÄJavaScript£»
±àдÈçÏÂС³ÌÐò£º
<html>
<script language = "javascript">
var sum = 0;
var start = new Date;
for(var i = 0; i < 1000001; i++){
sum+=i;
}
var stop = new Date;
document.write("´Ó1µ½1000000µÄÀÛ¼Ó½á¹û£º" + sum + ";" + "<br/> ......
<script language="javascript" type="text/javascript">
function arrayTest() {
//ʹÓÃnew Array()
var array1 = ......
×÷Õß
Dionysios G. Synodinos
ÒëÕß
ºî²®Þ±
·¢²¼ÓÚ
2010Äê5ÔÂ21ÈÕ ÏÂÎç9ʱ38·Ö
Akshell
ÊÇÒ»ÖÖÔÆ·þÎñ£¬ËüʹÓ÷þÎñ¶ËµÄ
JavaScriptºÍÔÚÏßµÄIDE°ïÖú¿ª·¢Õß½øÐпìËÙÓ¦ÓóÌÐò¿ª·¢¡£ Ëü»¹ÌṩÔÆÍйܣ¬ËùÒÔ ......
js.js
var xmlDoc;
function cleanData(getObj)
{
if(getObj)
{
getObj.options.length = 0;
}
}
function getxmlDoc()
{
xmlDoc=new ActiveXObject("Microsoft.XMLDOM");
......