You are here

function notifications_field_real_value in Notifications 6.4

Convert field value from submission into its real value

3 calls to notifications_field_real_value()
notifications_field_parse_submitted in includes/object.inc
Collect submitted fields and parse new values
Notifications_Subscription::validate_submission in includes/notifications_subscription.class.inc
Validate form submission
notifications_subscription_list_form_validate in ./notifications.pages.inc
Submit list of subscriptions

File

includes/object.inc, line 304
Notifications object and fields

Code

function notifications_field_real_value($type, $value) {
  if (!notifications_field_valid_value($value)) {
    return NULL;
  }
  elseif ($info = notifications_field_get_info($type, 'value callback')) {

    // We have a value callback for field or object so use it
    return _notifications_info_callback($info, 'value callback', array(
      $value,
    ));
  }
  else {

    // As we have nothing better, return the value itself
    return $value;
  }
}