title: I have got some error ajax
body: <p>I have an error where I can't proceed my login_process.php using ajax. I have stored all my files as a one folder. If I run my HTML log in page, the error is appeared. Below is my code. It is just a simple code. Before this, I have applied the similar code as below (except for login_process.php because I've put a few functions) as my homework. But when I've try to make it again, as i said, the browser, either in Chrome or Firefox, displays an error as I wrote in ajax below. </p>
  
  <p><strong>index.html(ajax part)</strong></p>
  
  <pre><code>$(document).ready(function(){
          $("#subBTN").click(function(){
              var username = $("#username").val();
              var password = $("#password").val();
              var status = $("#statusAlert");
  
              if(username === "" &amp;&amp; password === ""){
                  status.html("&lt;span&gt;Username and password are both required!&lt;/span&gt;");
              }
              else if(username === ""){
                  status.html("&lt;span&gt;What is your username?&lt;/span&gt;");
              }
              else if(password === ""){
                  status.html("&lt;span&gt;What is your password?&lt;/span&gt;");
              }
              else{
                  $.ajax({
                      url:'login_process.php',
                      type: 'post',
                      data: {"?admin_name=": username, "&amp;admin_pass=": password},
                      dataType: 'html',
                      success: function(data){
                          //alert(data);
                          if(data.success){                           
                              status.html("&lt;span&gt;"+ data +"&lt;/span&gt;");
                          }
                          else{                               
                              status.html("&lt;span&gt;error&lt;/span&gt;");
                              return false;   
                          }
                      }       
                  }); 
              }
          });
      });
  </code></pre>
  
  <p><strong>login_process.php</strong></p>
  
  <pre><code>&lt;?php
  session_start();
  
  if($_POST):
      $username = $_POST["username"];
      $password = $_POST["password"];
  
      if($username):
          echo "Hi " . $username;
      endif;
  endif;
  ?&gt;
  </code></pre>