title: Storing Session Variable on button click, HTML, PHP
body: <p>I am having trouble storing Session variable on a button click. I am trying do this without use of a form. Here is the code I have for my html and PHP.</p>
  
  <pre><code>&lt;?php
  session_start();
  
  if(isset($_GET['oldsignin'])) {
     $username = $_GET['oldusername'];
     $_SESSION['oldusername']= $username;
    }
  ?&gt;
  </code></pre>
  
  <p>Below is my html file:</p>
  
  <pre><code>&lt;div class="form-group"&gt;
          &lt;label for="text"&gt;Username:&lt;/label&gt;
          &lt;input id = "oldusername" type="text" class="form-control" name="user" placeholder="Enter Username" required&gt;
          &lt;a class="usersignin" name="oldsignin" data-role="button" style="background: blue; color: white;"&gt;Sign In&lt;/a&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>Thanks Guys for your help and suggestions.</p>