You are here

function entityform_mollom_form_info in Entityform 7

Same name and namespace in other branches
  1. 7.2 entityform.module \entityform_mollom_form_info()

Implements hook_mollom_form_info().

File

./entityform.module, line 1627
Module for the Entityform Entity - a starting point to create your own Entity and associated administration interface

Code

function entityform_mollom_form_info($form_id) {

  // Retrieve internal type from $form_id.
  $entityform_type = drupal_substr($form_id, 0, -21);
  $type = entityform_type_load($entityform_type);
  $form_info = array(
    // @todo This is incompatible with entityform access.
    'bypass access' => array(
      'bypass entityform access',
    ),
    'bundle' => $type->type,
    'bypass access' => array(
      'edit any entityform',
      'delete any entityform',
    ),
  );
  mollom_form_info_add_fields($form_info, 'entityform', $type->type);
  return $form_info;
}