HTML and CSS Reference
In-Depth Information
function OnError(err) {
alert(err.status + " - " + err.statusText);
This code is similar to Listing 2-16, with a minute difference: the URL where the POST request is sent is
of the form <controller_name>/<action_method_name> . If you run the MVC application, you should get the
same results as in the case of the Web Forms application.
HTML5 features can be programmed with plain JavaScript, but using a library such as jQuery provides
greater richness of functionality and ease of use. jQuery is a popular JavaScript library that makes your
client-side scripting a breeze. Using the power of jQuery selectors, you can select HTML DOM elements
based on complex conditions. You can also manipulate the HTML DOM on the fly. jQuery comes to the
rescue when you need to pass data between client and server. And jQuery Ajax techniques let you make
requests to the server without submitting the entire page.
This chapter gave you an overview of core jQuery features such as event handling, selectors, DOM
manipulation, and Ajax techniques. You use these features (and a few more) throughout the remainder of
the topic. With these skills under your belt, it's time to explore the HTML5 audio and video APIs in the next
Search WWH ::

Custom Search