CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Linking CiviCRM profile fields with Drupal ldap_integration module
Pages: [1]

Author Topic: Linking CiviCRM profile fields with Drupal ldap_integration module  (Read 2268 times)

xmatt

  • Guest
Linking CiviCRM profile fields with Drupal ldap_integration module
October 29, 2007, 11:44:13 am
Howdy folks,

We have a Drupal (5.3) installation with CiviCRM 1.9. I currently have the Drupal ldap_integration and ldap_provisioning modules installed, which let the Drupal account system insert accounts directly into the LDAP directory and authenticate against them. I'm using ldap_data to map LDAP attributes to Drupal profile fields. We're using OpenLDAP on Ubuntu Linux.

Essentially what I want to do is have a user be able to come by, create an account, and then edit their profile's email address, first/last name, address, etc. and have it simultaneously map back to both their LDAP record and their CiviCRM contact record. The problem is that ldap_data only sees Drupal's profile fields, not CiviCRM profile fields. The exception is the email address, which is not a custom profile field. That is mapped to both LDAP and CiviCRM.

As far as I can tell, my options are...
a.) modify the ldap_data module to dig into the CiviCRM database to find fields, or
b.) write my own module to detect edits to the CiviCRM fields and map them back to LDAP.

Both of these would be serious undertakings. Before I start a project like that, or just give up because it would take too long, I was wondering if anyone had had any success with this sort of setup.

Thanks!

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Linking CiviCRM profile fields with Drupal ldap_integration module
October 29, 2007, 01:18:40 pm

This page might help you out a wee bit: http://wiki.civicrm.org/confluence/display/CRMDOC/CiviCRM+LDAP+Integration (i dont think its directly related to what you want, but gives you some other options)

I suspect modifying ldap_data to use 'drupal hooks' to get / set the various civicrm fields is potentially doable (and less hackish if you can use the hooks)

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

xmatt

  • Guest
Re: Linking CiviCRM profile fields with Drupal ldap_integration module
October 29, 2007, 01:52:47 pm
Thanks. I actually have looked at that page at length. Its purpose seems to be to represent the CiviCRM contacts database as an LDAP directory so that applications like Outlook et al. can use it. A worthy purpose but it is a little different from what I want to do.

I will probably end up trying to hack up ldap_data to make it get/set CiviCRM fields. I'll report back if/when I succeed.

xmatt

  • Guest
Re: Linking CiviCRM profile fields with Drupal ldap_integration module
November 05, 2007, 03:08:37 pm
I'm sure you've all been waiting with bated breath for the results of my foray. Well, I modified the ldapdata.module code a little bit to make CiviCRM profile fields available to map in the LDAP Data admin form. More info and a patch for ldapdata.module is here:

http://drupal.org/node/189590

I'm beginning to think maybe I'm the only person who's needed to do this, but if it's useful to you, enjoy!

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Linking CiviCRM profile fields with Drupal ldap_integration module
November 05, 2007, 03:33:47 pm
You might want to cross-reference your work on the CiviCRM - LDAP Integration page on our wiki as way to help other folks find it. I suspect others will find this useful going forward.
Protect your investment in CiviCRM by  becoming a Member!

xmatt

  • Guest
Re: Linking CiviCRM profile fields with Drupal ldap_integration module
November 06, 2007, 07:26:39 am
No problem. I posted some instructions on the Wiki page. Hopefully it proves useful to some folks.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Linking CiviCRM profile fields with Drupal ldap_integration module

This forum was archived on 2017-11-26.