HTML Logo by World Wide Web Consortium (www.w3.org). 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 compo.sr for our new site, and to our migration roadmap. Existing ocPortal member accounts have been mirrored.


Improving forum integration

Login / Search

 [ Join | More ]
 Add topic 
Posted
Rating:
#22389 (In Topic #5404)
Avatar

Via editing the forums source code

ocPortal features good cookie integration with third party forums, so that when you log into ocPortal, the forum logs in, and when you log into the forum, ocPortal logs in. When you log out of ocPortal, the forum logs out - but when you log out of the forum, ocPortal does not automatically log out.

The reason for the last omission is because the forum can't tell ocPortal to delete the ocPortal login session. ocPortal is forum-aware (and thus deletes the forum login session when ocPortal logs out), but third-party forums are unfortunately not ocPortal-aware.

However, don't fear. With a little bit of editing of the forum source code you can change this. All you need to do is add a line in the right place.

For IPB 2.1, you add a line after line 817 of sources/action_public/login.php, so:

Code

      $this->ipsclass->my_setcookie( "anonlogin" , "-1" );
becomes:

Code

      $this->ipsclass->my_setcookie( "anonlogin" , "-1" );
      setcookie('ocp_session','',time()-100000,'/');

All I've done is tell the system to delete ocPortal's session cookie after the forum deletes it's own.


ocProducts can't actively help all our individual users to modify the code of third party software due to the time required, the complexity of the explanations, and the ever-changing forum-software landscape – so we can't officially support this. Our hope is that by explaining things we're laying a foundation for members of our community to help each other out in the future.


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
 
Posted
Rating:
#22396
Avatar

Community saint

Thanks this will be great and works great too.

I run http://otakuplayground.com and am hopping to make themes and other things for ocportal even though I no longer use it for otakuplayground.com I still love it and feel it could go far with the right help. It needs themes and needs people to advertise for it.
Back to the top
 
Posted
Rating:
#22397
Avatar

Fan in action

*Claps*

Thanks for that. Glad it didnt stay that I needed to pay for that lol. This is true support.

Thanks again.
Back to the top
 
Posted
Rating:
#22398
Avatar

Community saint

ya ocportal is awsome when it comes to support.
Hope they keep up the good work.

I run http://otakuplayground.com and am hopping to make themes and other things for ocportal even though I no longer use it for otakuplayground.com I still love it and feel it could go far with the right help. It needs themes and needs people to advertise for it.
Back to the top
 
1 guests and 0 members have just viewed this: None
Control functions:

Quick reply   Contract

Your name:
Your message: