javascript ajax implementation in your web application:
javascript ajax implementation: in this tutorial, I will show you how to implement Ajax use JavaScript. There I will help you display elements stored in an XML file to implement a simple Ajax script in your web application.
If you are learner or experience, whatever you need to know AJAX uses JavaScript to send and receive results between a web browser and a web server. Here you can display XML contents by the JavaScript.
In modern technology, AJAX technology makes web pages more responsive, in exchange for web page feedback, with data on the Web server.
Example:
<!DOCTYPE html> <html> <head> <title>JavaScript Ajax implementation</title> </head> <body> <div id="changeID"> <p>Ajax implementation</p> <button type="button" onclick="loadElement()">Change Element</button> </div> <script> function loadElement() { var xhttp = new XMLHttpRequest(); xhttp.onreadystatechange = function() { if (this.readyState == 4 && this.status == 200) { document.getElementById("changeID").innerHTML = this.responseText; } }; xhttp.open("GET", "mypage.php", true); xhttp.send(); } </script> </body> </html>
Related posts