sarebbe corretto scrivere
codice:
if ((document.getElementById("padre"))==false) }
     document.write ("false");
  }
else {document.write("true")}

???