SHARE
TWEET

Untitled

a guest Jul 20th, 2017 59 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var js_xmlHttp=false;
  2.  
  3. function runAjax(){
  4.     js_xmlHttp=new XMLHttpRequest();
  5.    
  6.     var js_temp1=document.getElementById("id_username").value;
  7.     var js_temp2=document.getElementById("id_password").value;
  8.    
  9.     var js_data="username="+js_temp1+"&password="+js_temp2;
  10.        
  11.     js_xmlHttp.open("POST","Display_Ajax.php",true);
  12.        
  13.     js_xmlHttp.onreadystatechange=function(){
  14.         if(js_xmlHttp.readyState==4 && js_xmlHttp.status==200){
  15.             document.getElementById("id_display").innerHTML=js_xmlHttp.responseText;
  16.         }
  17.     }
  18.    
  19.     js_xmlHttp.send(js_data);  
  20. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top