function paranoia_form_validate_always_fail in Paranoia 8
Same name and namespace in other branches
- 7 paranoia.module \paranoia_form_validate_always_fail()
Form validation that will always throw an error to prevent submits.
1 string reference to 'paranoia_form_validate_always_fail'
- paranoia_form_alter in ./
paranoia.module - Implements hook_form_alter().
File
- ./
paranoia.module, line 288 - Disables PHP block visibility permission and gives status error if a role has this permission. Disables the PHP module. Hides the PHP and paranoia modules from the modules page. Prevents user/1 editing which could give access to abitrary contrib…
Code
function paranoia_form_validate_always_fail() {
$form_state
->setErrorByName('', t('This form is disabled for security reasons. See <a href="https://www.drupal.org/node/2313945">details</a> on why this form is disabled.'));
}