title: How to fetch data of html form fields using jquery ajax from daabase
body: <p>Let's have a example:
  file.html</p>
  
  <pre><code>&lt;input type="text" name="txtname" id="txtname"&gt;
  &lt;input type="text" name="txtemail" id="txtemail"&gt;
  &lt;input type="text" name="txtaddress" id="txtaddress"&gt;
  </code></pre>
  
  <p>now file.php</p>
  
  <pre><code>assume connection already done and the variable $con.
  $userid = $_SESSION['userid'];
  $qry = mysqli_query($con, "SELECT name, email, address from users where id='$userid'");
  $row = mysqli_fetch_array($qry);
  $txtname= $row['name'];
  $txtemail = $row['email'];
  $txtaddress = $row['address'];
  </code></pre>
  
  <p>Now i don't want to write any single code of php in the html file let it be pure hmtl. also do not want to write any html code in php file let it be pure php.</p>
  
  <p>is there any secure (minimum) way to put the results of php files in respective form field of the html file using jquery ajax???</p>
  
  <p>may be it is a stupid question. But i want to with clarification as i am learning now. i do not want to use PDO and OOPS as i don't know.</p>