function wf_crm_array2str in Webform CiviCRM Integration 7.5
Same name and namespace in other branches
- 7.3 webform_civicrm_utils.inc \wf_crm_array2str()
- 7.4 includes/utils.inc \wf_crm_array2str()
Convert an array into a | separated string
Parameters
array $arr: Array of select options
Return value
string String representation of key => value select options
5 calls to wf_crm_array2str()
- webform_civicrm_node_load in ./
webform_civicrm.module - Implements hook_node_load().
- webform_civicrm_update_7300 in ./
webform_civicrm.install - Note: There are differences in how contact references and relationships work in the 3.x branch. Read the upgrade instructions at http://drupal.org/node/1615380
- wf_crm_admin_component::postProcess in includes/
wf_crm_admin_component.inc - Custom Processing for CiviCRM webform component option lists
- wf_crm_admin_form::insertComponent in includes/
wf_crm_admin_form.inc - Add a CiviCRM field to a webform
- wf_crm_webform_preprocess::fillForm in includes/
wf_crm_webform_preprocess.inc - Recursively walk through form array and set properties of CiviCRM fields
File
- includes/
utils.inc, line 1624 - Webform CiviCRM module's common utility functions.
Code
function wf_crm_array2str($arr) {
$str = '';
foreach ($arr as $k => $v) {
$str .= ($str ? "\n" : '') . $k . '|' . $v;
}
return $str;
}