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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T22:19:28+00:00 2026-05-27T22:19:28+00:00

Our web site makes use of showModalDialog . Based on what is done within

  • 0

Our web site makes use of showModalDialog. Based on what is done within the dialog, we may or may not wish to reload the page that opened the dialog. We do this by having the dialog JavaScript set window.returnValue to true or false, and then the underlying page inspects that in the return value of the call to showModalDialog.

This works fine when the dialog document and underlying page are loaded from the same origin domain. As is typical with the web, when the dialog’s domain doesn’t match the page’s, the return value from showModalDialog is always undefined.

I’ve entertained passing the flag from the dialog to the underlying window in different ways. Fortunately, we’re targeting browsers that all support postMessage, but the dialog JavaScript doesn’t appear to be getting a value for window.opener, so I don’t think it can get a reference to the window so it can post a message. Implementing an iframe workaround like this is unfeasible with our code base because it would require us to install iframe recipient documents on multiple sites that can all open this same dialog.

Is there a better way for us to have a dialog communicate with cross-origin opening pages without requiring that they reload?

  • 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-27T22:19:29+00:00Added an answer on May 27, 2026 at 10:19 pm

    I may have found my own answer. From what I understand, if I set the document.domain property for both the opener document and the dialog document to the same value, I should be able to access this information. Since both are within subdomains of the same root domain name, it should work. If I try this and it works, I will accept this answer.

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

Sidebar

Related Questions

On our web site, users enter free form text like Ribeye steak at Safeway
A section of our web site calls for asking the user 20 multiple-choice questions
Couple of months ago, we revamped our web site. We adopted totally new site
I need to offer scheduling of actions/events, in our web site. A crap analogy
We're running ASP.Net 2.0 on our corporate web site, and I'd like to get
I've been using log4net to log our ASP.NET web site's log messages, and lately
On our web application I am trying to ping a 3rd party site to
One of our web designers is working on a site at the moment and
I'm about ready to launch our company's web site on Amazon's EC2, and have
We are building a new SharePoint 2007 web site to replace our intranet website

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.