Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logged out of iframes, not main page #49

Open
elector-zz opened this issue Oct 9, 2017 · 4 comments
Open

Logged out of iframes, not main page #49

elector-zz opened this issue Oct 9, 2017 · 4 comments

Comments

@elector-zz
Copy link

I have a javascript SPA application where I am loading pages as iframes into javascript made tabs. Using Ext.JS components.
When logout happens, it logs out from the tab iframes but not the main page.
Any solution for this please?

@JillElaine
Copy link
Owner

Are the main page and the i-frame pages from the same domain & sub-domain? Are you loading the idleTimeout script only once for your site? Please load the idleTimeout-for-testing script and watch the Javascript console for errors. Perhaps you will be able to see where the script is not passing the logout function from the i-frame to the main page.

@elector-zz
Copy link
Author

It's all coming from the same domain and the script is loaded once. I'll give it try with the testing script. Thank you for a super fast reply!

@elector-zz
Copy link
Author

elector-zz commented Oct 9, 2017

I have found that the following change works in my scenario:

logoutUser = function () {
  store.set('idleTimerLoggedOut', true);

  if (currentConfig.sessionKeepAliveTimer) {
    stopKeepSessionAlive();
  }

  if (currentConfig.customCallback) {
    currentConfig.customCallback();
  }

  if (currentConfig.redirectUrl) {
  from: window.location.href = currentConfig.redirectUrl;
  to: window.top.location.href = currentConfig.redirectUrl;
  }
};

@JillElaine
Copy link
Owner

Thank you for your research and proposed solution. I am not able to make changes to the code at this time, but will leave your issue open so that others with this problem can see it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants