You are here

function vkxp_form_alter in VK CrossPoster 7

Same name and namespace in other branches
  1. 6.3 vkxp.module \vkxp_form_alter()
  2. 6 vkxp.module \vkxp_form_alter()
  3. 6.2 vkxp.module \vkxp_form_alter()

Implements hook_form_alter().

File

./vkxp.module, line 114

Code

function vkxp_form_alter(&$form, &$form_state, $form_id) {

  // Get node types that could be crossposted.
  $enabled_node_types = variable_get('vkxp_node_types', array());
  $selected_types = array_filter($enabled_node_types);
  foreach ($selected_types as $node_type) {
    if ($form_id == $node_type . '_node_form') {
      _vkxp_process_node_form($form);
    }
  }
}