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 »
  • Post-installation Setup and Configuration (Moderator: Dave Greenberg) »
  • How to ouput custom profile fields from civicrm to drupal user profiles
Pages: [1]

Author Topic: How to ouput custom profile fields from civicrm to drupal user profiles  (Read 1087 times)

vandit09

  • Guest
How to ouput custom profile fields from civicrm to drupal user profiles
July 22, 2008, 02:33:11 am
Basically, I want to be able to output custom profile fields created through civicrm and be able to output them into a drupal user profile as shown with standard contact info in this link http://drupal.org/node/133855

As per the comments section of that link, i was able to spit out individual contact fields, but what i really hope to do also, is to spit out custom fields from civicrm. Anybody can shed some light in this one?

Thanks in advanced.
 
- Gilbert

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: How to ouput custom profile fields from civicrm to drupal user profiles
July 22, 2008, 03:02:38 am

You should call the api function with all the custom fields you need

so

Code: [Select]
$params = array( 'contact_id' => CONTACTID,
                           'return.display_name' => 1,
                           'return.custom_1' => 1,
                           'return.custom_2' => 1,
                           'return.custom_3' => 1 );
$contact = civicrm_contact_get( $params );

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

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Post-installation Setup and Configuration (Moderator: Dave Greenberg) »
  • How to ouput custom profile fields from civicrm to drupal user profiles

This forum was archived on 2017-11-26.