FormValidator::doValidateForm

protected FormValidator::doValidateForm(&$elements, FormStateInterface &$form_state, $form_id = NULL) Performs validation on form elements. First ensures required fields are completed, #maxlength is not exceeded, and selected options were in the list of options given to the user. Then calls user-defined validators. Parameters $elements: An associative array containing the structure of the form. \Drupal\Core\Form\FormStateInterface $form_state: The current state of the form. The current

hook_tokens

hook_tokens($type, $tokens, array $data, array $options, \Drupal\Core\Render\BubbleableMetadata $bubbleable_metadata) Provide replacement values for placeholder tokens. This hook is invoked when someone calls \Drupal\Core\Utility\Token::replace(). That function first scans the text for [type:token] patterns, and splits the needed tokens into groups by type. Then hook_tokens() is invoked on each token-type group, allowing your module to respond by providing replacement text for any of the tokens

user_delete

user_delete($uid) Delete a user. Parameters int $uid: A user ID. File core/modules/user/user.module, line 844 Enables the user registration and login system. Code function user_delete($uid) { user_delete_multiple(array($uid)); }

CSS_AGGREGATE_THEME

The default aggregation group for theme CSS files added to the page. File core/includes/common.inc, line 79 Common functions that many Drupal modules will need to reference. Code const CSS_AGGREGATE_THEME = 100;

hook_node_access_records

hook_node_access_records(\Drupal\node\NodeInterface $node) Set permissions for a node to be written to the database. When a node is saved, a module implementing hook_node_access_records() will be asked if it is interested in the access permissions for a node. If it is interested, it must respond with an array of permissions arrays for that node. Node access grants apply regardless of the published or unpublished status of the node. Implementations must make sure not to grant access to unpublish

Updater::postInstall

public Updater::postInstall() Performs actions after installation. File core/lib/Drupal/Core/Updater/Updater.php, line 388 Class Updater Defines the base class for Updaters used in Drupal. Namespace Drupal\Core\Updater Code public function postInstall() { }

TaxonomyController::addForm

public TaxonomyController::addForm(VocabularyInterface $taxonomy_vocabulary) Returns a form to add a new term to a vocabulary. Parameters \Drupal\taxonomy\VocabularyInterface $taxonomy_vocabulary: The vocabulary this term will be added to. Return value array The taxonomy term add form. File core/modules/taxonomy/src/Controller/TaxonomyController.php, line 24 Class TaxonomyController Provides route responses for taxonomy.module. Namespace Drupal\taxonomy\Controller Code public functio

EntityDisplayRepositoryInterface::getViewModeOptionsByBundle

public EntityDisplayRepositoryInterface::getViewModeOptionsByBundle($entity_type_id, $bundle) Returns an array of enabled view mode options by bundle. Parameters string $entity_type_id: The entity type whose view mode options should be returned. string $bundle: The name of the bundle. Return value array An array of view mode labels, keyed by the display mode ID. File core/lib/Drupal/Core/Entity/EntityDisplayRepositoryInterface.php, line 81 Class EntityDisplayRepositoryInterface Provides

EntityForm

Base class for entity forms. Hierarchy class \Drupal\Core\Form\FormBase implements ContainerInjectionInterface, FormInterface uses DependencySerializationTrait, LoggerChannelTrait, LinkGeneratorTrait, RedirectDestinationTrait, UrlGeneratorTrait, StringTranslationTraitclass \Drupal\Core\Entity\EntityForm implements EntityFormInterface Related topics Entity API Describes how to define and manipulate content and configuration entities. File core/lib/Drupal/Core/Entity/EntityForm.php, line 16

BlockLibraryController::listBlocks

public BlockLibraryController::listBlocks(Request $request, $theme) Shows a list of blocks that can be added to a theme's layout. Parameters \Symfony\Component\HttpFoundation\Request $request: The current request. string $theme: Theme key of the block list. Return value array A render array as expected by the renderer. File core/modules/block/src/Controller/BlockLibraryController.php, line 91 Class BlockLibraryController Provides a list of block plugins to be added to the layout. Names