HTML Logo by World Wide Web Consortium ( Click to learn more about our commitment to accessibility and standards.

Moving forward with Composr

ocPortal has been relaunched as Composr CMS, which is now in beta. ocPortal 9 will be superseded by Composr 10.

Head over to for our new site, and to our migration roadmap. Existing ocPortal member accounts have been mirrored.

Facebook Integration and login

Login / Search

 [ Join | More ]
 Add topic 
#101232 (In Topic #19858)

Community saint

Has anyone else noticed that the Facebook integration does not maintain your login for as long as it use to ?

The main scenario that I notice it is when you have not used the forum for a while and then you get an email to a post you are monitoring. Clicking this link would use to take you to the post logged in via the stored Facebook credentials. But more often than not now it just takes you to the post in a non logged in state - this is annoying, particularly on a phone as you have to go to your profile block, click the Facebook link to login and then navigate back to the original post.

Anyone else experiencing this ?


Last edit: by Lhasadreams
Back to the top

Community saint

I tried a test again this morning.
A email received yesterday with a link to a thread that can only be seen by a certain group.
Clicking the link takes you to a login page that says Guest does not have access. But it actually logs you in, but does not redirect to the requested page. If you go back and click the email link it takes you straight to the post.

Is there a way to remain permanently logged in once you have logged in via Facebook ?
Back to the top

Facebook login is achieved via Javascript and cookies, which is the standard integration Facebook provide. It is also possible to do it on the server directly, which is where I'd like to take things in the future, but it means major rewriting.

Because it happens in Javascript, if there is no ocPortal session anymore, the page will be served as Guest until Facebook's Javascript code sets a new Facebook session, then we refresh, then ocPortal turns it into an ocPortal session.

You could increase the ocPortal session length, but it's not really advisable, as it lowers security (longer sessions = greater risk of attack by someone trying to steal session IDs).

ocPortal shouldn't take you somewhere else. Our refresh code only takes you to the website front page if you were actually logging in from a URL with 'login' in it (i.e. the login page). I suppose you could have something like a forum topic with 'login' in the URL moniker which could be erroneously triggering that, or there could be a bug. If you can report clearly where the original link was and where you ended up (obfuscated if required) I might be able to spot something.

I use Facebook login myself extensively and it tends to be pretty solid.

Become a fan of ocPortal on Facebook or add me as a friend. Add me on on Twitter.
Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about ocPortal whenever you see the opportunity.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying ocPortal on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Back to the top
1 guests and 0 members have just viewed this: None
Control functions:

Quick reply   Contract

Your name:
Your message: