You are here

function views_bulk_operations_forms in Views Bulk Operations (VBO) 6

Same name and namespace in other branches
  1. 5 views_bulk_operations.module \views_bulk_operations_forms()
  2. 6.3 views_bulk_operations.module \views_bulk_operations_forms()

Implementation of hook_forms().

Force each instance of function to use the same callback.

File

./views_bulk_operations.module, line 891
Allows operations to be performed on items selected in a view.

Code

function views_bulk_operations_forms($form_id, $args) {

  // Ensure we map a callback for our form and not something else.
  $forms = array();
  if (strpos($form_id, 'views_bulk_operations_form_') === 0) {

    // Let the forms API know where to get the form data corresponding
    // to this form id.
    $forms[$form_id] = array(
      'callback' => 'views_bulk_operations_form',
      'callback arguments' => array(
        $form_id,
      ),
    );
  }
  return $forms;
}