<script> <br>$(document ).ready(function () { <br>$("#b01").click(function () { <br>htmlobj = $.ajax({ url: "/Content/upFile/test.txt", async: false }); <br>$("#div01").html(htmlobj.responseText); <br>}); <br>}); <br><br>$(document).ready(function () { <br>$("#test").load("/Content/upFile/test2.txt #p1", function (responseTxt, statusTxt, xhr) { <br>if (statusTxt == "success") <br>alert("External content loaded successfully!" xhr); <br>if (statusTxt == "error") <br>alert("Error: " xhr.status ": " xhr.statusText); <br>} ); <br>}); <br><br>$(document).ready(function () { <br>$("#getbutton").click(function () { <br>$.get(" /DownSet/index", function (data, status) { <br>alert("data:" data "nstatus:" status); <br>}); <br>}); <br>}); <br><br>$(document).ready(function () { <br>$("#postbutton").click(function () { <br>$.get("/CustomerInformation/getS", { par: "ww" }, function (data, status) { <br>alert("data:" data "nstatus:" status); <br>$("#postText").html(data); <br>} ); <br>}); <br>}); <br><br></script>
After the get method loads the text, it will be displayed here
jquery The load method loads is displayed here After loading the text, it will be displayed here
The text will be displayed here after loading < input type="button" value="Load text" id="b01"/>