How to automatically close the parent window when the child window is opened in Firefox
<p>i have this code i need to close the parent.html window when the child window opened, i need the code for that working well in IE and Firefox</p>

<p>Parent.html</p>

<pre><code>&lt;HTML&gt;
  &lt;SCRIPT TYPE="text/javascript"&gt;
  function sendTo()
  {
  window.open('child.html','_blank','resizable=yes,width='+(screen.width-500)+',height='+(screen.height-500)+'');

  }
  &lt;/SCRIPT&gt;
  &lt;BODY&gt;
  &lt;form name="form"&gt;
    &lt;input type="text" value="" name="text1" id="pdetails1"&gt;
    &lt;input type="text" value="" name="text1" id="pdetails2"&gt;
    &lt;/br&gt;
    &lt;input type="submit" value="submit" onClick="sendTo()"&gt;
  &lt;/BODY&gt;
&lt;/HTML&gt;
</code></pre>

<p>child.html</p>

<pre><code>&lt;html&gt;
  &lt;body&gt;
    &lt;form&gt;
      &lt;input type=text name="text5" value=""&gt;
      &lt;input type=submit name="submit"value="submit"&gt;
    &lt;/form&gt;
  &lt;/body&gt;
&lt;/html&gt;
</code></pre>
