You are here

function phonefield_field_update_instance in Phone Field 7

Implements hook_field_update_instance().

File

./phonefield.module, line 535
Hooks for a module that defines a simple phone number field type.

Code

function phonefield_field_update_instance($instance, $prior_instance) {
  if (function_exists('i18n_string_update') && isset($instance['widget']) && $instance['widget']['type'] == 'phonefield_field' && $prior_instance['settings']['linkvalue'] != $instance['settings']['linkvalue']) {
    $i18n_string_name = "field:{$instance['field_name']}:{$instance['bundle']}:linkvalue";
    i18n_string_update($i18n_string_name, $instance['settings']['linkvalue']);
  }
}