How to post data to a page and navigate to another page in php
<p>I'm posting data to a page and after that I want to navigate to another page at the same  time. I'm using a javascript to post the data and I checked it be echoing its values and it works fine when I send only post data but when I'm redirecting to another page and try to access those post data it seems to be not set. 
and by the way what I have written is a javascript like this </p>

<pre><code>function getsupport ( selectedtype )
</code></pre>

<p>{
  document.folderCreation.supporttype.value = selectedtype ;
  document.folderCreation.submit() ;
  document.location.href="../../index.php";</p>

<p>}</p>

<p>and in the form :</p>

<pre><code>&lt;form action="index.php" name="folderCreation" method="POST" &gt;
      &lt;input type="hidden" name="supporttype" /&gt;&lt;?php
 while($row = mysql_fetch_array($rs)) 
  {
      $filePath=$row['pathFromImages']; 
      $id=$row['id'];
      ?&gt;

      &lt;a href="javascript:getsupport('&lt;?php  echo $filePath;?&gt;')" &gt;&lt;?php echo $filePath;?&gt;&lt;/a&gt;
      &lt;/br&gt;

&lt;?php 
</code></pre>

<p>this form values are posted correctly when the line :document.location.href="../../index.php"; is not there. Why is this not working?..</p>

<p>Thanks in advance.</p>
