ÒÔÏÂÃæµÄframeΪÀý£º
(1)·ÃÎÊframe¶ÔÏó:
IE:ʹÓÃwindow.frameId»òÕßwindow.frameNameÀ´·ÃÎÊÕâ¸öframe¶ÔÏó. Firefox:Ö»ÄÜʹÓÃwindow.frameNameÀ´·ÃÎÊÕâ¸öframe¶ÔÏó.
ÁíÍ⣬ÔÚIEºÍFirefoxÖж¼¿ÉÒÔʹÓÃwindow.document.getElementById( \À´·ÃÎÊÕâ¸öframe¶ÔÏó.
(2)Çл»frameÄÚÈÝ:
ÔÚIEºÍFirefoxÖж¼¿ÉÒÔʹÓÃwindow.document.getElementById( \\»òwindow.frameName.location = \À´Çл»frameµÄÄÚÈÝ.
Èç¹ûÐèÒª½«frameÖеIJÎÊý´«»Ø¸¸´°¿Ú£¬¿ÉÒÔÔÚfrmeÖÐʹÓÃparentÀ´·ÃÎʸ¸´°¿Ú¡£Àý È磺parent.document.form1.filename.value= \
14.bodyÎÊÌâ
FirefoxµÄbodyÔÚbody±êǩûÓб»ä¯ÀÀÆ÷ÍêÈ«¶ÁÈë֮ǰ¾Í´æÔÚ£»¶øIEµÄbodyÔò±ØÐëÔÚbody±êÇ©±»ä¯ÀÀÆ÷ÍêÈ«¶ÁÈëÖ®ºó²Å´æÔÚ. ÀýÈ磺 Firefox£º
15. ʼþίÍз½·¨
IE£ºdocument.body.onload = inject; //Function inject()ÔÚÕâ֮ǰÒѱ»ÊµÏÖ
Firefox£ºdocument.body.onload = inject();
ÓÐÈË˵±ê×¼ÊÇ£º
document.body.onload=new Function( 'inject() ');
16. firefoxÓëIE(parentElement)µÄ¸¸ÔªËصÄÇø±ð
IE£ºobj.parentElement firefox£ºobj.parentNode
½â¾ö·½·¨: ÒòΪfirefoxÓëIE¶¼Ö§³ÖDOM,Òò´ËʹÓÃobj.parentNodeÊDz»´íÑ¡Ôñ.
17.cursor:hand VS cursor:pointer
firefox²»Ö§³Öhand£¬µ«ieÖ§³Öpointer
½â¾ö·½·¨: ͳһʹÓÃpointer
18.innerTextÔÚIEÖÐÄÜÕý³£¹¤×÷£¬µ«ÊÇinnerTextÔÚFireFoxÖÐÈ´²»ÐÐ.
½â¾ö·½·¨:
if(navigator.appName.indexOf( \
document.getElementById( 'element ').innerText = \ } else{
document.getElementById( 'element ').textContent = \ }
19. FireFoxÖÐÀàËÆ obj.style.height = imgObj.height µÄÓï¾äÎÞЧ
½â¾ö·½·¨£º
obj.style.height = imgObj.height + 'px ';
20. ie,firefoxÒÔ¼°ÆäËüä¯ÀÀÆ÷¶ÔÓÚ table ±êÇ©µÄ²Ù×÷¶¼¸÷²»Ïàͬ£¬ÔÚieÖв»ÔÊÐí¶ÔtableºÍtrµÄinnerHTML¸³Öµ£¬Ê¹ÓÃjsÔö¼ÓÒ»¸ötrʱ£¬Ê¹ÓÃappendChile·½·¨Ò²²»¹ÜÓá£
½â¾ö·½·¨£º
//Ïòtable×·¼ÓÒ»¸ö¿ÕÐУº var row = otable.insertRow(-1);
var cell = document.createElement( \cell.innerHTML = \cell.className = \row.appendChild(cell);
Ïà¹ØÍÆ¼ö£º