Getting started with jquery (reposted to blog), jquery blog

Source: Internet
Author: User

Getting started with jquery (reposted to blog), jquery blog

Address: http://www.cnblogs.com/zhangziqiu/archive/2009/04/30/jQuery-Learn-1.html

 

Learning jQuery (I) from scratch

Learning jQuery (2) omnipotent selector from scratch

Learning jQuery from scratch (3) Managing jQuery packaging Sets

Learning jQuery from scratch (4) using jQuery to operate on attributes and styles of Elements

Learning jQuery (5) Events and event objects from scratch

Learning Ajax in jQuery (6) from scratch

Learning jQuery (7) jQuery animation from scratch-let the page go!

Learning jQuery (8) Plug-in from scratch: jQuery implementation solution

Learning jQuery (9) jQuery tool functions from scratch

Learning jQuery (10) Common jQueryUI functions from scratch

Learning jQuery (11) practical form verification and Automatic completion prompt plug-in from scratch

 

 

What is jQuery?

JQuery is a Javascript script library. in my blog, I can find the "Javascript lightweight script library" series of articles. the Javascript script library is similar.. NET class library. We encapsulate some tool methods or object methods in the class library for your convenience.

Note that jQuery is a script library rather than a script framework. "library" is not equal to "framework". For example, "System assembly" is a class library, while "ASP. net mvc "is the framework. jQuery does not help us solve the Reference Management and function Management of scripts. These are what the script framework is doing.

The script library can help us complete the encoding logic and implement business functions. using jQuery will greatly improve the efficiency of writing javascript code and make the written code more elegant and robust. at the same time, the rich jQuery plug-ins on the network have turned our work into "drinking tea every day with jQuery"-because we have already stood on the shoulders of giants.

When you create an ASP. net mvc project, you will find that the jQuery class library has been automatically introduced. jQuery is almost a powerful script library of Microsoft! The perfect integration and smart sensing support allow. NET and jQuery to be seamlessly integrated! Therefore, to use. NET, you need to use jQuery instead of Dojo and ExtJS.

JQuery has the following features:

1. provides powerful functions

Using these functions can help us quickly complete various functions and make our code very concise.

2. Solve browser compatibility issues

The compatibility of javascript scripts in different browsers has always been a nightmare for Web developers. A page often runs normally in IE7 and Firefox, and some inexplicable problems occur in IE6. writing different scripts for different browsers is a pain point. with jQuery, we will wake up from this nightmare. For example, the Event event object in jQuery has been formatted as common in all browsers. In the past, we had to obtain the Event Trigger Based on the event, in ie, It is event. under the standard browser such as srcElements and ff, event.tar get. jqueryis a unified eventobject, so that we can use event.tar get in a browser to get the event object.

3. Implement rich UI

JQuery can achieve animation effects such as gradient pop-up and layer movement, so that we can have a better user experience. taking the gradient effect as an example, I wrote a gradient animation that is compatible with ie and ff. It was implemented using a large amount of javascript code, so it took a lot of effort to avoid it, after writing the script, I forgot it for a while without much help. it is effort-consuming to develop similar functions. now, using jQuery can help us quickly complete such applications.

4. Script knowledge for Error Correction

I proposed this article because most developers have incorrect understanding of javascript. for example, compile the DOM statement that is executed during loading on the page, directly add the "onclick" attribute to the HTML element or document object, and do not know that onclick is actually an anonymous function. technicians with these error scripts can complete all the development work, but such programs are not robust. for example, "write the DOM statement that is executed when loading in the page", there is no problem when the Page code is very small and users load quickly, when the page loading is slow, the browser "stop operation" error will occur. jQuery provides a lot of simple methods to help us solve these problems. Once jQuery is used, you will be able to correct these errors-because we all use standard and correct jQuery scripting methods!

5. Too many! Wait for us to discover them one by one.

 

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.