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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T00:29:33+00:00 2026-05-16T00:29:33+00:00

I have a box with a link in it, and I have an event

  • 0

I have a box with a link in it, and I have an event handler on the link that makes it create a jQuery dialog from the box when clicked. This part works fine. However, when I close the dialog, I want to restore the original box. It looked to me like .dialog(“destroy”) ought to do just that, since it’s described as “returning the element to its pre-init state”, but that’s not working. Is there any way to do this without something silly like cloning the box before creating the dialog and then reinserting 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-16T00:29:33+00:00Added an answer on May 16, 2026 at 12:29 am

    I didn’t have success with this too. My solution was:

    var boxContainer = $('popupContainer');
    $(this).find(popupClass).dialog({
       close: function(event, ui){
         boxContainer.append($(this).html());
         $(this).remove();
       },
       ....
    });
    

    It’s working, although for me it’s an “ugly” solution. Of course you can tune a little bit the example, but it’s just my way.

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

Sidebar

Related Questions

I have jQuery that uses the change event from a selection box to update
I have a drop down menu that looks like this: It works fine, but
So I have a light box that's dynamically loaded from a common.js file. (Legacy
It appears that the Blur event stops the click event handler from working? I
I have a modal box that has a text on it and a link
I am fetching data from the following database: I have arduino-box that send that
I have a page, and on that page I create an event. Time passes,
I am having some trouble with jQuery. I want to have a dialog box
I have a login box that slides/toggles up and down when an <a> link
I currently have a registration form which when clicked from a link opens up

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.