title: Pass the parameters in the HTML URL to php
body: <p>So I have a <code>html</code> file and a <code>php</code> file and what I am trying to do is to pass the values in the html <code>URL</code> parameters to my <code>php</code>.</p>
  
  <p>So for example if the URL was <code>localhost\files\reset_username.html?args=erft5467uio$d</code> - then the <code>erft5467uio$d</code> bit should be captured in the <code>$_GET('args')</code> in my <code>php</code>. Problem is this value is not being passed onto the <code>php</code> file itself.</p>
  
  <p>This is <code>html</code> file:</p>
  
  <pre><code>&lt;html&gt;
      &lt;form id='setUsername' action='setnewusername.php' method='post'&gt;
      &lt;label for='username' &gt;New Username: &lt;/label&gt;
      &lt;input type='text' name='usernameInput' id='username'  /&gt;
      &lt;label for='newUsername' &gt;Confirm Username: &lt;/label&gt;
      &lt;input type='text' name='newUsernameInput' id='newUsername' /&gt;
      &lt;input type='text' name='Submit' value='Change Username' /&gt;
      &lt;/form&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>This is my <code>php</code> code:</p>
  
  <pre><code>&lt;?php
  require "init.php";
  
  if(!empty($_GET['args']) &amp;&amp; !empty($_GET['usernameInput'])){
      $paramOne = $_GET['args'];
      $paramTwo = $_GET['usernameInput'];
      echo $paramOne;
      echo $paramTwo;
  } 
  else{
      echo "The args was not received";
  }
  
  ?&gt;
  </code></pre>
  
  <p>When I was testing my code, the php prints <code>"The args was not received"</code>. This means that the value <code>erft5467uio$d</code> was not passed.</p>
  
  <p>How do I pass such values to the <code>php</code> script?</p>
  
  <p><strong>EDIT:</strong>
  Every time a user requests to have their username changed they receive a link with a unique <code>args</code> value. In this case, the user receives an email with the link <code>localhost\files\reset_username.html?args=erft5467uio$d</code> in this case to their email. When they click on the link they are directed to the html page. Upon filling  out the form, the code <code>erft5467uio$d</code> as well as the <code>usernameInput</code> has to be passed to the php</p>
  
  <p>Thanks </p>