function node_revision_delete_content_type_configuration_delete_form in Node Revision Delete 7.3
Page callback: Form constructor for content type configuration delete form.
Parameters
array $form: The form element.
array $form_state: The form state.
Return value
array The form definition
1 string reference to 'node_revision_delete_content_type_configuration_delete_form'
- node_revision_delete_menu in ./
node_revision_delete.module - Implements hook_menu().
File
- ./
node_revision_delete.admin.inc, line 358
Code
function node_revision_delete_content_type_configuration_delete_form(array $form, array &$form_state) {
$content_type_machine_name = arg(5);
// Getting all the content types.
$content_types = node_type_get_names();
// Getting the content type name.
$content_type_name = $content_types[$content_type_machine_name];
// The question.
$question = t('Are you sure you want to delete the configuration for the "%content_type" content type?', array(
'%content_type' => $content_type_name,
));
// The cancel url.
$cancel_url = 'admin/config/content/node_revision_delete';
// The description.
$description = '<p>' . t('This action will delete the Node Revision Delete configuration for the "@content_type" content type, if this action take place the content type will not be available for revision deletion.', array(
'@content_type' => $content_type_name,
)) . '</p>';
$description .= '<p>' . t('The action cannot be undone.') . '</p>';
// Submit and calcel button text.
$submit = t('Delete');
$cancel = t('Cancel');
// Creating the confirm form.
$form = confirm_form($form, $question, $cancel_url, $description, $submit, $cancel);
return $form;
}