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 7930387
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T20:24:15+00:00 2026-06-03T20:24:15+00:00

I want to add a function to jQuery UI Dialog. I want to do

  • 0

I want to add a function to jQuery UI Dialog. I want to do that without actually downloading .js file with jQuery UI Dialog source code and editing it. Is it possible to do this from separate .js file?

Some further explanation: let’s say I want to add custom function that’s called e.g. “func1”. After I’ve coded it, I should be able to call it like this:

($"#dialog").dialog("func1");

Is that possible without editing original jQuery Dialog source code?

  • 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-03T20:24:17+00:00Added an answer on June 3, 2026 at 8:24 pm

    Ok, I’ve finally found the answer 😀

    (function($){
        var _init = $.ui.dialog.prototype._init;
    
        //Init
        $.ui.dialog.prototype._init = function() {
            var self = this;
                    _init.apply(this, arguments);
    
                  //here you can do custom init
        };
    
        //Custom Dialog Functions
        $.extend($.ui.dialog.prototype, {
            func1: function() {
                            alert("f1");
            },
            func2: function() { 
                alert("function 2");
            }
        });
    })(jQuery); 
    

    I have figured it out from this post :

    http://www.droptoframe.com/?p=35

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

Sidebar

Related Questions

I'm using this code sample that came from jquery-ui website to show the dialog
I have an onclick function that I want to add an anchor to the
I don't mean an alias or function. I actually want to add an entire
I want to add some custom HTML between the buttons on a jQuery dialog
How to do a doOnce function? I have this jQuery script and I want
I have this jQuery code: <script type=text/javascript > $(function() { $('#add_comment').bind('submit',function() //$(input[type=submit]).click(function() { var
I'm trying to make Jquery delete function, here is the code, that I wrote
I created webservice which contain Add function as 'webmethod' when we want to deploy
I want add my custom sidebar next right column all page. Please check this
I have a list of string values that I want add to a hashtable

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.