- oriented. NET Developer's AJAX technology platform strategy
Here I will try to examine the present. NET platform under the AJAX framework, I also try to summarize a method that allows you to be based on many. NET platform, find the right one for
Read the example on the website of Okajax, learn Ajax, oneself imitate done, really good, the following his code announced;
First, create a new page, the HTML code to overwrite the original HTML,. cs File No need to thank any code
Untitled Page
function Ajax () {var xmlhttpreq = null;//declares that an empty object is used to mount the XMLHttpRequest if window. ActiveXObject) {//ie5 IE6 is the ActiveXObject way to introduce xmlhttprequest xmlhttpreq = new ActiveXObject ("Microsoft.XMLHTTP")
get Sina short URL Length URL: enter your App_key (no searchable online): : Calling Address: click me URL:--> Reference article: Take short chain service as an example, to explore the Appkey-free, authentication-free, Ajax Cross-domain
The AJAX request and form's Submit method set the request in the same way as it did, using method: ' POST ' settings
Form submission
Winform.getform (). Submit ({
waittitle: ' Hint ',//title
waitmsg: ' Submitting data Please later ...
AJAX
AJAX=
asynchronous JavaScript and XML. Asynchronous JavaScript and XML. Ajax is the technique of exchanging data and updating portions of a Web page without having to reload the entire page. Traditional Web pages must reload
Three steps to achieve this function:
1, the mother page:
"
===================================
2, the background action method:
=====================================
Public Actionforward Showexam (actionmapping mapping, Actionform
JScript files
function creatxmlhttp ()//Create XMLHttpRequest Object{if (ActiveXObject){XMLHTTP = new ActiveXObject ("Microsoft.XMLHTTP")}else if (XMLHttpRequest){XMLHTTP = new XMLHttpRequest ();}return XMLHTTP;}
function CreateQuery ()//Create
When dealing with the scrollbar problem in the TreeView list, it was found that many popular processing methods did not work, and found that it was not possible to use this popular practice in the master AJAX environment. So self-reliance, with the
Ajax JSON interaction and SPRINGMVC in @requestbodyBackgroundProvide it yourself. The parameters in the interface are set to @requestbody Vippromotionlog Vippromotionlog as an object. But the front-end personnel have to deal with the code as follows
0. Cross-domain security issuesIn the course of learning springboot, we encountered such a problem. At that time, the rest service interface was developed with Springboot, and then the data was obtained with Ajax request to realize the separation of
But we are going to commit with AJAJX similar to: Array (' id ' =>12,data = = Array (' A ' =>1, ' B ' =>2) '); When the data of a two-dimensional array, the direct AJAX submission background is not received, and requires special handling:Only
Front-End Code:Passing values through AJAX, the return value of the Chinese garbled problem$.ajax ({ URL:' buyercartmorehandle ', type:' post ', ' application/ x-www-form-urlencoded; Charset=utf-8 ",
21st Native (native)Ajaxworking with InstancesMethods for creating XMLHttpRequest objectsfunction Createxmlhttprequest () {if (window. ActiveXObject) {return new ActiveXObject ("Microsoft.XMLHTTP");}else if (window. XMLHttpRequest) {return new
Native JS implements Ajax://method: Request Way Post/get;//URL: If it is a Get method, the URL will have parameters//obj: Ready container for easy storage of the data you getfunctionXHR ($method, $url, obj){ varRequest =NewXMLHttpRequest ();
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.