11.4. Controls Now Exposed As jQuery Plug-Ins

In this release, all the ASP.NET AJAX controls are exposed as jQuery plug-ins. So, you can instantiate them using jQuery syntax, even using jQuery's chaining capabilities. The following code attaches an ASP.NET AJAX watermark control to a text box and an ASP.NET AJAX color picker:

Sys.require([Sys.scripts.jQuery, Sys.components.watermark, Sys.components.colorPicker]);
   Sys.onReady(function () {
   $("#txtChooseColor").watermark("Choose a color", "watermarked").colorPicker();
});

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.216.197.92