rem: var page=document.firstChild; 
add: var page=document.documentElement; 
context: function onInit() {  try {    include('chrome://jslib/content/io/dir.js');    //include('chrome://jslib/content/io/fileUtils.js');  }  catch(ex) {    var page=document.firstChild;    for(var i=0; i<page.childNodes.length; i++) {      if(page.childNodes[i].getAttribute("id") != "noJSlib")        page.childNodes[i].setAttribute("collapsed","true");    }    return;  }  document.getElementById("noJSlib").setAttribute("collapsed","true");  /* This probably isn't the desired way to save mail preferences,     but it is backward-compatible with TagZilla's old way of doing it */  var els = document.getElementsByAttribute("prefstring","*");  for( var i in els ) {    if( !(els[i] && els[i].getAttribute) ) continue;    var prefstring = els[i].getAttribute("prefstring").replace( /%identitykey%/, gIdentity.key );    var preftype = els[i].getAttribute("preftype");    var prefattr = els[i].getAttribute("prefattribute");    var result = readMyPref( prefstring, preftype, null );    if(prefattr == "value")      els[i].value = result;    else      els[i].setAttribute(prefattr, result);  }}
meta: 1647	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/1647/d2551f35984a552551ffe7f584f99f8f620e2087/am-tzprefs.js/clean/src/tagzilla/content/am-tzprefs.js