title: Form data disappear after refresh in php
body: <p>Hi I am new to <code>PHP</code> and here I am developing a mulit page form, but as soon as page is refreshed, entered data is disappeared, below code is I am writing.</p>
  
  <pre><code>&lt;?php 
  if(isset($_POST['name'])){
      echo $_POST['name'].'&lt;br/&gt;';
  }
  ?&gt;
  
  
  &lt;form method="POST" action=""&gt;
  &lt;p&gt;NAME&lt;/p&gt;
  &lt;input type="text" name="name" value="&lt;?php 
                                        if(isset($_POST['name'])){
                                            echo htmlentities ($_POST['name']);
                                        } 
                                        ?&gt;" /&gt; 
  &lt;br/&gt;
  &lt;input type="submit" value="keep value" name="submit"/&gt; &lt;br/&gt;
  
  &lt;/form&gt;
  </code></pre>