jquery is not easy to say love you

Source: Internet
Author: User

jquery is a set of cross-browser JavaScript libraries that simplifies the operation between HTML and JavaScript. The first version was released by John Resig on the January 2006 BarCamp NYC. It is currently being developed by the development team led by Dave Methvin. Of the top 10,000 most visited websites in the world, 59% use jquery, which is currently the most popular JavaScript library.

When you start learning, you are not accustomed to using jquery, writing code or writing native JavaScript unconsciously. And not to get used to new things. Then I asked myself to write with jquery as much as I could, to try something new.

After studying for one weeks jquery. To understand the power and convenience of jquery in the beginning. In jquery columns such as animate () a small method can be ever-changing.

Just like before to do a similar with similar QQ customer service always hover on the right side of the page and can expand the menu navigation.

  

(<ul>

<li><a>1</a><label>flash Material </label></li>

<li><a>2</a><label>flash Material </label></li>

<li><a>3</a><label>flash Material </label></li>

</ul>)

Just like the above ul let each Li move in turn, if the native JS to write so how many Li will need to set how many properties.

But now with jquery (

var $this = $ (this);

var f_time = 0;

$this. Find (' Li '). each (function () {

$ (this). Stop (). Delay (f_time+=50). Animate ({ight: ' -150px '}, 100);})

Just like this, a few simple lines of code will do.

In fact, the power of jquery is not only so, there are many places to expand. I think jquery is mainly about practicing with more.

So, jquery, it's not easy to say love you. You have to practice more.

jquery is not easy to say love you

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.