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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T04:11:23+00:00 2026-05-28T04:11:23+00:00

I am opening a dialog box with a button click event. Dialog box contains

  • 0

I am opening a dialog box with a button click event. Dialog box contains ok and cancel button. In IE it works normaly but in firefox dialog is opening ‘cancel’ button is working but ‘ok’ button nothing is happening.

Below is the code of a button in which i am opening a dialog.

$('#addImage').click(function ()
{
    var url = 'Default.aspx'; 
    var d = $('#dialog_img').html('<iframe id="ifrm" , width = 540 , height = 170></iframe>');
    $("#dialog_img>#ifrm").attr("src", url);
    d.dialog('open').dialog({ modal: true ,width: 560,resizable: false , 
        buttons: 
        {
            'OK': function() {
                 var img = document.createElement('img');
                $(img).attr("id", "dyndiv" + count);
                $(img).attr("width", 30);
                $(img).attr("height", 50); 
                $(img).attr("src", 'Uploads/'+window.frames['ifrm'].document.getElementById('dvFileName').innerHTML) ;
                var $ctrl = $(img).resizable({ containment: '#containment-wrapper'}).parent().addClass("resizable mydiv").draggable({
                    containment: '#containment-wrapper',
                    cursor: 'move',
                    delay: 200,
                    distance: 30,
                    opacity: 0.35
                })
                objid = "dyndiv" + count;
                $(img).css("z-index" , $(img).css("z-index") + count );
                $('#sel_obj_text').val("Image");
                image_visibility();
                count++; 
                $("#containment-wrapper").append($ctrl);
                $('#' + objid).parent().css("position","relative"); 
                $('#' + objid).parent().position({
                    of: $( "#containment-wrapper" ),
                    my: "center" + " " + "center",
                    at: "center" + " " + "center"
                });                   

                $(this).dialog('destroy');
            },
            'Cancel': function() {
                $(this).dialog('destroy');
            }
        }
    });
}); 
  • 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-28T04:11:23+00:00Added an answer on May 28, 2026 at 4:11 am

    You’re missing a semi-colon (;) after your $ctrl declaration.

    In your original code, its this line:

    var $ctrl = $(img).resizable({ containment: '#containment-wrapper'}).parent().addClass("resizable mydiv").draggable({ containment: '#containment-wrapper', cursor: 'move',delay: 200,distance: 30, opacity: 0.35})
    

    In the edited code:

    var $ctrl = $(img).resizable({ containment: '#containment-wrapper'}).parent().addClass("resizable mydiv").draggable({
        containment: '#containment-wrapper',
        cursor: 'move',
        delay: 200,
        distance: 30,
        opacity: 0.35
    })  // <-- Missing semi-colon (;)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to Record with Selenium IDE Click on Firefox dialog box for Opening
I am wondering how I can go about stopping a dialog from opening if
When opening a window, I register a Deleted-event-handler on my business object. It is
I have a jquery dialog box that is used to edit and update a
When i click the c-drive it is now opening , instead it showing the
I have a CustomInstaller class (System.Configuration.Install.Installer) and basically I'm opening a dialog form at
About Gtk Dialog box Behavior... I am using GtkBuilder +Glade to display a top
I'm opening a modal dialog for IE6 and above using the following javascript. window.showModalDialog(
I would like to embed the FontDialog control into a settings dialog box for
Hello everyone iam trying to open a aspx page in a dialog box window

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.