case 'AdvMulti-Select':
case 'Multi-Select':
if (is_array($value)) {
+ if ($html_type == 'CheckBox') {
+ // CRM-12989 fix
+ CRM_Utils_Array::formatArrayKeys($value);
+ }
+
$checkedData = $value;
}
else {
* @param int $fileID
* @param bool $absolute
*
+ * @param string $multiRecordWhereClause
+ *
* @return array
*/
public static function getFileURL($contactID, $cfID, $fileID = NULL, $absolute = FALSE, $multiRecordWhereClause = NULL) {
$customFields[$customFieldId]['html_type'] == 'AdvMulti-Select'
) {
if ($value) {
- // Note that only during merge this is not an array,
- // and you can directly use value, CRM-4385
- if (is_array($value)) {
- $value = CRM_Core_DAO::VALUE_SEPARATOR . implode(CRM_Core_DAO::VALUE_SEPARATOR,
- array_values($value)
- ) . CRM_Core_DAO::VALUE_SEPARATOR;
- }
+ $value = CRM_Utils_Array::implodePadded($value);
}
else {
$value = '';