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

  • Home
  • SEARCH
  • 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 6318377
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T15:37:54+00:00 2026-05-24T15:37:54+00:00

I am loading up a framework (Microsoft AJAX Framework) along with Prototype and an

  • 0

I am loading up a framework (Microsoft AJAX Framework) along with Prototype and an autocomplete textbox. Both the framework and the autocomplete are adding behavior to some textboxes. I usually want both snippets to run, but not at all times. Basically, if an autocomplete item has been selected, I dont want the framework JS to run.

I thought I would try to overwrite the framework using a technique like this: Overriding a JavaScript function while referencing the original.

var original_doSomething = doSomething;
doSomething = function() 
{ 
    //do something *else* 
    if(something) original_doSomething();
}

However, the framework is a little clever and has been proving difficult to overwrite event handler is retaining the original function. I wrote a jsfiddle to mock the situation. http://jsfiddle.net/jeffrod/haHD4/2/

Is there anyway to overwrite dosomething so I can add my own logic to it??

  • 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-05-24T15:37:55+00:00Added an answer on May 24, 2026 at 3:37 pm

    Can you just change this function yourself:

    $(function()
    {
        var someObject = { 'a':'aaa' }
        $('input').keypress(createHandler(someObject,dosomething));
    });
    

    Or reassign the keypress handler yourself. That function is binding dosomething to the event before you have a chance to change dosomething yourself.

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

Sidebar

Related Questions

Some loading routines in my program takes to long to complete. I want a
I just found out that lazy loading in Entity Framework only works from the
Brief Background: My team has decided to use Microsoft's Managed Extensibility Framework ( MEF
I want to download .net framework 3.5 sp1 to install on client computer (just
In Entity Framework 4, what is the difference between Lazy Loading, and using Load()
What's the following NHibernate lazy loading equivalent to Entity Framework? product.Categories.Add(s.Load<Category>(cat)); I tried this,
Does silverlight provide a mechanism like full .NET framework's AppDomain for loading and unloading
I am using .Net framework 2.0 / jQuery to make an Ajax call to
I'm writing an automated test framework where after each action (loading a new page
There appear to be a lot of unnecessary frameworks loading into my iPhone app.

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.