Webmastersite.net
Register Log In

Integration Help
Full Integration With Drupal?

Comments on Integration Help

joshwa
Beginner

Usergroup: Customer
Joined: Apr 16, 2006

Total Topics: 1
Total Comments: 4
joshwa
Posted Apr 16, 2006 - 7:02 AM:

I'm trying to get WSN Links to integrate fully with drupal. I've used the integration generator and can get it to work more or less with the usernames, users still have to login for both, since the cookie is a session id. I was wanting to integrate the systems more fully and was wondering if it would be possible without a major change in the codebase.

What I need to do is use a single sign on
Have WSN Links integration use multiple tables within the database.

Would this be an easy customization or more of a complete rework?
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Apr 17, 2006 - 11:55 AM:

What query does drupal use to get the member id based on the cookie value? I'd have no problem making it a standard integration if I had that info (along with the rest of your integration file).

Set $cookietype = 'session';
Open classes/member.php, find
 $q = $db->query("SELECT user_id FROM geodesic_sessions WHERE classified_session='". $sessionid ."'");
, change as appropriate.
joshwa
Beginner

Usergroup: Customer
Joined: Apr 16, 2006

Total Topics: 1
Total Comments: 4
joshwa
Posted Apr 18, 2006 - 3:59 AM:

Thanks for the response Paul

The integration data I have is:
$memberstable = 'users';

$newusergroup = 'uid';
$newname = 'name';
$newid = 'uid';
$newpassword = 'pass';
$newemail = 'mail';
$newtime = 'added';

$otherencoder = 'no';

$admingroup = '1';

$idcookiename = '';
$passwordcookiename = '';
$cookietype = 'session';
$idindex = '';
$passwordindex = '';
$cookieidtype = '';

the query came out to:
$q = $db->query("SELECT uid FROM sessions WHERE sid='". $sessionid ."'");

I'm sure there's a lot of people that would be interested in this since drupal doesn't have a built in directory and most people settle for hacking it's modules to get a simple links list with categories

The configuration above is a hack because the roles are stored in an additional table as well as a lot of the other integration fields so only the first user can be an admin in drupal and wsnlinks but worked for me with a single signon

Thanks for the help
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Apr 18, 2006 - 9:08 PM:

I don't see how that could work without a cookie name... what's the name of the cookie which the session id is in? You don't seem to have one listed above.

Note I've made a drupal.php integration file based on the above (despite the lack of cookie name) which will make your upgrades work properly (so that you don't have to re-edit classes/members.php after an upgrade).
joshwa
Beginner

Usergroup: Customer
Joined: Apr 16, 2006

Total Topics: 1
Total Comments: 4
joshwa
Posted Apr 21, 2006 - 9:12 AM:

soory Paul it's the standard PHPSESSID
Search thread for
Download thread as
  • 0/5
  • 1
  • 2
  • 3
  • 4
  • 5



This thread is closed, so you cannot post a reply.