UrbanPro

Learn Web Development from the Best Tutors

  • Affordable fees
  • 1-1 or Group class
  • Flexible Timings
  • Verified Tutors

Search in

Difference between bind and live method in jquery?

Asked by Last Modified  

Follow 2
Answer

Please enter your answer

Trainer

The .live() method uses the concept of event delegation to perform its so called "magic". The way you call .live() looks just like how you might call .bind(), which is very convenient. However, under the covers this method works much different. The .live method attaches the event handler to the root...
read more
The .live() method uses the concept of event delegation to perform its so called "magic". The way you call .live() looks just like how you might call .bind(), which is very convenient. However, under the covers this method works much different. The .live method attaches the event handler to the root level document along with the associated selector and event read less
Comments

UI And WEB Technologies

These two are event attaching methods in Jquery, bind can be used for existing elements where as live can be used for both existing , future elements too. But in latest versions Jquery these two methods deprecated and added new method called "ON".
Comments

Computer

1. bind() attacheds events to elements that exist or match the selector at the time the call is made. Any elements created afterwards or that match going forward because the class was changed, will not fire the bound event. 2 .live() works for existing and future matching elements. Before jQuery 1.4...
read more
1. bind() attacheds events to elements that exist or match the selector at the time the call is made. Any elements created afterwards or that match going forward because the class was changed, will not fire the bound event. 2 .live() works for existing and future matching elements. Before jQuery 1.4 this was limited to the following events: click, dblclick mousedown, mouseup, mousemove, mouseover, mouseout, keydown, keypress, keyup. read less
Comments

Bind works for existing elements while live works for existing and future elements. Both these features have now been replaced by "on".
Comments

Trainer

.bind() attacheds events to elements that exist or match the selector at the time the call is made. Any elements created afterwards or that match going forward because the class was changed, will not fire the bound event. .live() works for existing and future matching elements. Before jQuery 1.4 this...
read more
.bind() attacheds events to elements that exist or match the selector at the time the call is made. Any elements created afterwards or that match going forward because the class was changed, will not fire the bound event. .live() works for existing and future matching elements. Before jQuery 1.4 this was limited to the following events: click, dblclick mousedown, mouseup, mousemove, mouseover, mouseout, keydown, keypress, keyup read less
Comments

Front end developer and Trainer having 7 years of experience

.bind(): This is the easiest and quick method to bind events. But the issue with bind() is that it doesn't work for elements added dynamically that matches the same selector. bind() only attach events to the current elements not future element. Above that it also has performance issues when dealing with...
read more
.bind(): This is the easiest and quick method to bind events. But the issue with bind() is that it doesn't work for elements added dynamically that matches the same selector. bind() only attach events to the current elements not future element. Above that it also has performance issues when dealing with a large selection. .live(): This method overcomes the disadvantage of bind(). It works for dynamically added elements or future elements. Because of its poor performance on large pages, this method is deprecated as of jQuery 1.7 and you should stop using it. Chaining is not properly supported using this method. .delegate(): The .delegate() method behaves in a similar fashion to the .live() method, but instead of attaching the selector/event information to the document, you can choose where it is anchored and it also supports chaining. .on(): Since live was deprecated with 1.7, so new method was introduced named ".on()". This method provides all the goodness of previous 3 methods and it brings uniformity for attaching event handlers. read less
Comments

bind method works on static elements on the page. live() works for dynamic binding of elements in a page.
Comments

View 5 more Answers

Related Questions

Hello, I am working as a web designer, my skills are Html, CSS, CSS3, Bootstrap, Javascript, Jquery. Want to know what other skills should I have to know according to industry requirement?
Learn sass, and other tools that help in buidling frontend project like webpack. Also start learning reactjs or angular. Industry need fast development using any frontend framework
Mudita
Where is best training center for web development in Bangalore?
It is better please, you will contact any professional developer. because the person has a lot of working experience knowledge.Also you will be learn very quickly and company label. So please, you will don't go any training center.
Harsh
What software do professional web designers use?
WordPress, Adobe Dreamweaver, Sublime Text and openElement.
Neetu
0 0
5
As a web designer, should I learn Photoshop?
Not mandatory but it will help for better design
Nasar
0 0
5

Now ask question in any of the 1000+ Categories, and get Answers from Tutors and Trainers on UrbanPro.com

Ask a Question

Related Lessons

Morphing Page Transition
Today we’d like to share a simple morphing page transition effect with you. The idea is to morph an SVG path while moving an intro page up, creating an interesting, flowy look. For the animations...

Remote Learning Do's and Dont's
In the Present fast-paced world, people are facing challenges concerning keeping themselves always with the up to date technologies or industry changes. When it comes to the IT industry, it is becoming...
V

Why Should We Learn React
Nowadays, if we are talking about web development, then many web languages are available, but there are two things only: Front-end and back-end. For front-end, the browser only knows HTML, CSS and javascript....

Some good resources
Clean Code by Robert C Martin, is available in my profile please download and read it, irrespective of what language you code in, it will change the way you code. Also if you code in Javascript read https://12factor.net/ https://blog.risingstack.com/javascript-clean-coding-best-practices-node-js-at-scale/ For...

How to become a Successful IT Professional?
No matter what field you work in, you probably have some desires of professional success. Success is a word that may be defined in different ways by different people, but being a knowledgeable and dedicated...
S

Steadysteps

0 0
0

Recommended Articles

Today, no business can exist without having its own website to interact with its customer base. Having a website is no more restricted to the big MNCs. With the advancement in technology and global business, even the small enterprises are spending on having their own websites and development teams. The person works on web...

Read full article >

Applications engineering is a hot trend in the current IT market.  An applications engineer is responsible for designing and application of technology products relating to various aspects of computing. To accomplish this, he/she has to work collaboratively with the company’s manufacturing, marketing, sales, and customer...

Read full article >

Business Process outsourcing (BPO) services can be considered as a kind of outsourcing which involves subletting of specific functions associated with any business to a third party service provider. BPO is usually administered as a cost-saving procedure for functions which an organization needs but does not rely upon to...

Read full article >

Whether it was the Internet Era of 90s or the Big Data Era of today, Information Technology (IT) has given birth to several lucrative career options for many. Though there will not be a “significant" increase in demand for IT professionals in 2014 as compared to 2013, a “steady” demand for IT professionals is rest assured...

Read full article >

Looking for Web Development Classes?

Learn from the Best Tutors on UrbanPro

Are you a Tutor or Training Institute?

Join UrbanPro Today to find students near you
X

Looking for Web Development Classes?

The best tutors for Web Development Classes are on UrbanPro

  • Select the best Tutor
  • Book & Attend a Free Demo
  • Pay and start Learning

Learn Web Development with the Best Tutors

The best Tutors for Web Development Classes are on UrbanPro

This website uses cookies

We use cookies to improve user experience. Choose what cookies you allow us to use. You can read more about our Cookie Policy in our Privacy Policy

Accept All
Decline All

UrbanPro.com is India's largest network of most trusted tutors and institutes. Over 55 lakh students rely on UrbanPro.com, to fulfill their learning requirements across 1,000+ categories. Using UrbanPro.com, parents, and students can compare multiple Tutors and Institutes and choose the one that best suits their requirements. More than 7.5 lakh verified Tutors and Institutes are helping millions of students every day and growing their tutoring business on UrbanPro.com. Whether you are looking for a tutor to learn mathematics, a German language trainer to brush up your German language skills or an institute to upgrade your IT skills, we have got the best selection of Tutors and Training Institutes for you. Read more