jaz6ix
05-25-2010, 03:19 PM
status.net is a php microblogging platform and I would like to integrate it with my vBulletin. I also posted a similar question to stackoverflow.com http://stackoverflow.com/questions/2903935/sharing-a-session-between-vbulletin-forum-and-status-net-microblogging-platform but I figured I would get some better respond from here regarding hacking vBulletin. So here we go:
The first thing I need to do is make these 2 to share 1 session so a user logged in vBulletin forums will also be logged in to status.net and vice versa.
I have installed different vBulletin components under different subdomains:
1. forums.sample.com - vBulletin forums
2. blogs.sample.com - vBulletin blogs
3. sample.com - vBulletin content management
All of these point to the same place (.../public_html/index.php) which includes the respective php file (content.php for sample.com | blog.php for blogs.sample.com | forum.php for forums.sample.com) depending on the $_SERVER['HTTP_HOST']
I have configured vBulletin to use a single cookie.domain (.sample.com) for all of these 3 domains so visiting different domains doesn't break the session.
I also have status.sample.com, which is the subdomain where status.net is installed. The subdomain configuration is different so the document_root is actually a subfolder (.../public_html/status/) in sample.com
Now, can you please give me some pointers on how to make all these subdomains share a single session?
Similar to how vBulletin handles session, status.net stores sessions in database table called "session" as well and I couldn't find anything trivial in that table. 'started', 'session_id', 'user_id' and 'session_token' variables are worth mentioning what I could find in the session_data column after logging in (no serialized objects).
What are you thoughts on the idea of inserting a row at login and update started/lastactivity in both databases provided userid's match at both ends and is there a way to hook to the session update in vBulletin so I can synchronize the session with status.net?
Thank you
The first thing I need to do is make these 2 to share 1 session so a user logged in vBulletin forums will also be logged in to status.net and vice versa.
I have installed different vBulletin components under different subdomains:
1. forums.sample.com - vBulletin forums
2. blogs.sample.com - vBulletin blogs
3. sample.com - vBulletin content management
All of these point to the same place (.../public_html/index.php) which includes the respective php file (content.php for sample.com | blog.php for blogs.sample.com | forum.php for forums.sample.com) depending on the $_SERVER['HTTP_HOST']
I have configured vBulletin to use a single cookie.domain (.sample.com) for all of these 3 domains so visiting different domains doesn't break the session.
I also have status.sample.com, which is the subdomain where status.net is installed. The subdomain configuration is different so the document_root is actually a subfolder (.../public_html/status/) in sample.com
Now, can you please give me some pointers on how to make all these subdomains share a single session?
Similar to how vBulletin handles session, status.net stores sessions in database table called "session" as well and I couldn't find anything trivial in that table. 'started', 'session_id', 'user_id' and 'session_token' variables are worth mentioning what I could find in the session_data column after logging in (no serialized objects).
What are you thoughts on the idea of inserting a row at login and update started/lastactivity in both databases provided userid's match at both ends and is there a way to hook to the session update in vBulletin so I can synchronize the session with status.net?
Thank you