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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T02:16:57+00:00 2026-06-15T02:16:57+00:00

I want to be able to securely authenticate users on my site from any

  • 0

I want to be able to securely authenticate users on my site from any non-secure page. So I made a window.open() popup to open a secure sign in form. The plan is that after the user signs up or authenticates, the popup would close and the parent window would refresh.

Closing the popup works fine, however, due to Cross Site Scripting rules, when trying to refresh the parent, I get the following:

Unsafe JavaScript attempt to access frame with URL http://localhost/ from frame with URL https://localhost/signin_popup. The frame requesting access has a protocol of 'https', the frame being accessed has a protocol of 'http'. Protocols must match.

I can’t simply subscribe on at the parent to onunload, because the authentication popup may traverse through several pages before its ready to refresh the parent. I’m currently trying to see if I can bind custom events to the popup window object from the parent, and fire them from within the popup, but to no avail.

So…

How can I make a popup window interact with a parent window, or have the parent window subscribe to custom events of the popup window when protocols do not match?

  • 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-15T02:16:58+00:00Added an answer on June 15, 2026 at 2:16 am

    You should be able to implement cross-origin window communication with the postMessage-API

    To post a message to the other window:

    otherWindowRef.postMessage( 'message', origin );
    

    You will then receive it on the other window:

    window.addEventListener( "message", function() {
       //message was received 
    }, false );
    

    The other window will likewise .postMessage back to the main window and the main window gets a message event.

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

Sidebar

Related Questions

I want to be a able to securely send data from my Android App
I want to be able to hide a selector if it contains any data.
I want users to be able to use Facebook Connect on MY website. And
From a private area of my site developed in ASP.NET MVC I want to
I want to able to open a command prompt at the folder which contains
Motivation : I want be able to retrieve and view Certificates from a Windows
I want to be able to allow users to add their own options on
I'm using LaTeX and BibTeX for an article, and I want to able to
Want to be able to provide a search interface for a collection of objects
I want to be able to take an image that i have already captured

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.