0

I'm attempting to setup a autologin script on an external website, accessed through an iFrame.

i.e. iframe url="http://www.othersite.com/autologin/?token=029dd3df34ds"

That script should just check the token against DB, set a logged_in session if successful and then redirect.

It's just failing to set the session and I can't figure out why.

The odd thing here is that the normal login form (similar login, session handling) on this external site does work.

In both cases I am using header('P3P: CP="CAO PSA OUR"');

Any thoughts?

gio
  • 1
  • 1
  • This link could help you: http://stackoverflow.com/questions/389456/cookie-blocked-not-saved-in-iframe-in-internet-explorer – Tohid Sep 30 '11 at 20:46

1 Answers1

0

i think you should check the token against db and call to parent site with some attribute and then set the session on parent site itself. As you can't set session from one domain to other domain.

jit
  • 1,616
  • 3
  • 21
  • 49