In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces "what is the request method of Request Method". In the daily operation, I believe that many people have doubts about what the request method of Request Method is. The editor consulted all kinds of materials and sorted out simple and easy-to-use operation methods. I hope it will be helpful for you to answer the doubts of "what is the request method of Request Method?" Next, please follow the editor to study!
Request Method (request method)
GET mode is used by default, and POST mode is used if the data parameter provides an object.
Loading Page Fragments (load page snippet)
The .load () method, unlike $.get (), allows us to use special syntax to add specific parameters to the url to specify which part of the remote document to insert. If the string of the url parameter contains one or more spaces, the content after the first space is treated as a selector for jQuery, determining which part of the returned result should be loaded. (translator's note: the first space is followed by a jQuery selector, and the content returned that matches the selector will be loaded into the page. )
We can modify the example above, where only a portion of # container is loaded into the file:
$('# result'). Load ('ajax/test.html # container')
When this method is executed, it will retrieve the page content returned by ajax/test.html, jQuery will get the content that ID is container element, and insert ID as result element, while other elements that have not been retrieved will be discarded.
JQuery uses the browser's [xss_clean] property to parse the retrieved document and insert it into the current document. In the process, browsers usually filter some elements in the document, such as, or elements. As a result, the elements returned by the .load () method may not be exactly the same as the document content obtained directly from the browser.
Script Execution (script execution)
When the URL parameter is not followed by a selector expression, the return passed to .html () contains a script. Scripts are executed before they are discarded. But if you call .load (), even if the selector expression is added to the url parameter, the script will be deleted before the DOM is updated. Therefore, the script will not be executed. The following examples demonstrate these two situations:
Any JavaScript scripts loaded into # a will be executed as part of the document.
$('# a'). Load ('article.html')
However, the script block will be stripped from the document loaded into # b without execution in the following cases:
$('# b'). Load ('article.html # target')
At this point, the study of "what is the request method of Request Method" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.