You are here

function asin_text_validate in Amazon Product Advertisement API 6

Validate an select element.

Remove the wrapper layer and set the right element's value.

File

asin/asin.module, line 426
Defines a field type for referencing an Amazon product.

Code

function asin_text_validate($element, &$form_state) {
  array_pop($element['#parents']);
  form_set_value($element, $form_state['values'][$element['#field_name']], $form_state);
}