Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

156
Views
Keeping user logged in outside of an iframe

I'm using Laravel and Vue in an SPA and am integrating my app with another app. The second app has my app in an iframe. However, once my app is loaded in their iframe and a user is authenticated, I would like the user to have the option to open my app outside of the iframe by clicking on a button. After authenticating the user on my server, my plan was to send the JWT back to the client and then log in the user with the token (this is while my app is within the other app's iframe):

await this.$store.dispatch('auth/saveToken', {
  token: token
})

If I refresh the page within the iframe, then the user is logged in, so I know that this is working.

However, when I try to open in a new tab:

let route = this.$router.resolve({ path: this.url })
 window.open(route.href)

the user is logged out.

Am I missing a step so that the user will stay logged in even if the app opens in a new tab and outside of the original iframe?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

i think because of change browser, because iframe is different or you app is different, so you have to manage token for login if it's come on new browser, and you are not able to get token after store in vuex you need to pass in url or any other way.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!