Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7943163
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T00:11:15+00:00 2026-06-04T00:11:15+00:00

I am using JQuery .live to listen for a custom event, ie not .click,

  • 0

I am using JQuery .live to listen for a custom event, ie not .click, .change, .keyup or any of the native events, but rather an event that I create using jquery .trigger. I have several places in the application that listen for this event using .live. I want to remove a single handler from the event. None of the methods I’ve tried seem to work including, .unbind, .die, and .undelegate. I’m using jquery 1.6 so I can’t use .off. What’s the best way to accomplish this?

This is essentially the form my code takes. I call unbind first to remove the handler if it already exists.

OBJECT 1
{
    myNameSpace.MY_CUSTOM_EVENT_STRING = "my_event";

    $cachedFieldObject.trigger(myNameSpace.MY_CUSTOM_EVENT_STRING);
}

OBJECT 2
{
    function myfunctionName(var1) {myObject.myObjectsFunction()}

    $("#divID").find(".fieldClass").unbind(myNameSpace.MY_CUSTOM_EVENT_STRING, myfunctionName).live(myNameSpace.MY_CUSTOM_EVENT_STRING, myfunctionName);
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T00:11:17+00:00Added an answer on June 4, 2026 at 12:11 am

    live() attaches delegated event handlers to the document element so you’ll have to unbind them from the document element this fiddle shows how to unbind specific functions from live but not specific selected elements.
    EDIT:
    From the doc

  2. Chaining methods is not supported. For example, $(“a”).find(“.offsite, .external”).live( … ); is not valid and does not work as expected.
  3. It is possible to unbind custom events, but you have to do it for all bound elements
    In this fiddle the custom event only becomes unbound when all elements are unbound.

  • 0
  • Reply
  • Share
    Share
    • Share on Facebook
    • Share on Twitter
    • Share on LinkedIn
    • Share on WhatsApp
    • Report

Sidebar

Related Questions

I am using JQuery.live() functionality to trap click event of any label in a
I am binding a click event to an image using Jquery Live binding. The
I'm using jquery and creating event handlers like this: $('#some_selector a.add').live('click', function(){...}); However, I
When using .animate() while changing top / left , the click event does not
I'm using a very simple jQuery live preview method which works brilliantly. But how
Are there any disadvantages of using jQuery's 'live' consistently throughout my application? If i
Using jQuery Mobile (jquery.mobile-1.0b3.min.js). If i apply a click event to a form, the
Using JQuery it possible to clone a Div like this and change add a
Using jquery UI 1.8's autocomplete, is there any known way to take the results
I been sort of using jquery livequery plugin and jquery live together. However now

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.