title: Pass Data From Input Form on One Page To a Select Form on Another page?
body: <p>There are so many examples of passing data from one page to another using <code>GET</code> and <code>POST</code> in PHP.</p>
  
  <p>However what I am trying to do is a bit different.</p>
  
  <p>Here is what i need to do:</p>
  
  <p>I have an input textfield on one page (page1.php) and I need to pass its value/data to a Select form on another page (page2.php).</p>
  
  <p>I have this on page1.php:</p>
  
  <pre><code>&lt;form method="post" action="../page2.php"&gt;
    &lt;input type="text"/&gt;
    &lt;button name="location" type="submit"&gt;Search&lt;/button&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>And I have this on page2.php:</p>
  
  <pre><code>&lt;form id="myForm" name="myForm" class="myForm" method="post" action="page2.php"&gt;
    &lt;select style="font-size:9px;" name="timezone2" id="timezone2"&gt;
  
  &lt;option value="&lt;?php echo $_GET["location"]; ?&gt;"&gt; &lt;/option&gt;
  
  &lt;/select&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>when i run the page1.php from a browser, it will point me to the page2.php as it should but it will not show the Data/Value that was input in the  textfield <code>name="location"</code> !</p>
  
  <p>First off, is what I am trying to do possible?</p>
  
  <p>and if so, could someone please point me in the right direction please?</p>