function FormTestMachineNameForm::load
Same name in other branches
- 10 core/modules/system/tests/modules/form_test/src/Form/FormTestMachineNameForm.php \Drupal\form_test\Form\FormTestMachineNameForm::load()
Loading stub for machine name.
Parameters
string $machine_name: The machine name.
Return value
bool TRUE if the machine name is a duplicate, FALSE otherwise.
File
-
core/
modules/ system/ tests/ modules/ form_test/ src/ Form/ FormTestMachineNameForm.php, line 92
Class
- FormTestMachineNameForm
- Form constructor for testing #type 'machine_name' elements.
Namespace
Drupal\form_test\FormCode
public function load($machine_name) {
return str_contains($machine_name, 'duplicate');
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.