Differences between the live () method and bind () method in jquery, jquerybind

Source: Internet
Author: User

Differences between the live () method and bind () method in jquery, jquerybind

This article describes the differences between the live () method and the bind () method in jquery. We will share this with you for your reference. The details are as follows:

Live () is not affected by the loading time sequence. You only need to search for events that can be paired with each other. The bind method can only bind the time when it is loaded for the first time, if the matching element is loaded after the code, the corresponding event cannot be bound.

$ ("# Manual_disconnect "). live ("click", function () {connectionProfile ("0") ;}); $ ("# manual_disconnect "). die ("click ");

Note: The die () method is used to unbind live.

$ ("# Manual_disconnect "). live ("click", function () {connectionProfile ("0") ;}); $ ("# manual_disconnect "). unbind ("click ");

Note: The unbind () method is used to unbind live.

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.