function addfavorite(surl, stitle) { try { window.external.addfavorite(surl, stitle); } catch (e) { try { window.sidebar.addpanel(stitle, surl, ""); } catch (e) { try { window.external.addfavorite(surl.tostring(),stitle); } catch(e) { alert("加入收藏失败,请使用ctrl+d进行添加"); } } } } function sethome(obj,vrl) { try { obj.style.behavior='url(#default#homepage)'; obj.sethomepage(vrl); } catch(e) { if(window.netscape) { try { netscape.security.privilegemanager.enableprivilege("universalxpconnect"); } catch (e) { alert("此操作被浏览器拒绝!\n请在浏览器地址栏输入“about:config”并回车\n然后将 [signed.applets.codebase_principal_support]的值设置为'true',双击即可。"); } var prefs = components.classes['@mozilla.org/preferences-service;1'].getservice(components.interfaces.nsiprefbranch); prefs.setcharpref('browser.startup.homepage',vrl); } } } function mm_preloadimages() { //v3.0 var d=document; if(d.images){ if(!d.mm_p) d.mm_p=new array(); var i,j=d.mm_p.length,a=mm_preloadimages.arguments; for(i=0; i0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i