We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

Redirect from External website. Session not available

Hi,

My Project structure is

app /Controllers /Models /Views

Im trying to create a login through social media page. Here is how I have made it for twitter

Controllers: SocialConnect Auth

SocialConnectController.php

If(NO_SESSION_VARIABLES_AVAILABLE)
{
    destroySession();
    redirectToTwitterLogin()  /// From twitter it will return back this action
}else{  
    redirectToAuthController();
}

The problem is when the flow is redirected from Twitter to MyAPP the session is not avialble . So if I create the session and send it to Auth Controller , still I have to create a sesion in authcontroller's action

What am I doing wrong here?

Pseudo code is not really helpful when asking for advice ;]