responsive-image.html.twig

Default theme implementation of a responsive image. Available variables: sources: The attributes of the <source> tags for this <picture> tag. img_element: The controlling image, with the fallback image in srcset. output_image_tag: Whether or not to output an <img> tag instead of a <picture> tag. See also template_preprocess() template_preprocess_responsive_image() File core/modules/responsive_image/templates/responsive-image.html.twig Related topics Theme system

LoggerChannelFactoryInterface::get

public LoggerChannelFactoryInterface::get($channel) Retrieves the registered logger for the requested channel. Return value \Drupal\Core\Logger\LoggerChannelInterface The registered logger for this channel. File core/lib/Drupal/Core/Logger/LoggerChannelFactoryInterface.php, line 18 Class LoggerChannelFactoryInterface Logger channel factory interface. Namespace Drupal\Core\Logger Code public function get($channel);

SetSubtreesCommand::__construct

public SetSubtreesCommand::__construct($subtrees) Constructs a SetSubtreesCommand object. Parameters array $subtrees: The toolbar subtrees that will be set. File core/modules/toolbar/src/Ajax/SetSubtreesCommand.php, line 25 Class SetSubtreesCommand Defines an AJAX command that sets the toolbar subtrees. Namespace Drupal\toolbar\Ajax Code public function __construct($subtrees) { $this->subtrees = $subtrees; }

PathProcessorAlias::processInbound

public PathProcessorAlias::processInbound($path, Request $request) Processes the inbound path. Parameters string $path: The path to process, with a leading slash. \Symfony\Component\HttpFoundation\Request $request: The HttpRequest object representing the current request. Return value string The processed path. Overrides InboundPathProcessorInterface::processInbound File core/lib/Drupal/Core/PathProcessor/PathProcessorAlias.php, line 34 Class PathProcessorAlias Processes the inbound path

ContentEntityBase::__unset

public ContentEntityBase::__unset($name) Implements the magic method for unset(). File core/lib/Drupal/Core/Entity/ContentEntityBase.php, line 967 Class ContentEntityBase Implements Entity Field API specific enhancements to the Entity class. Namespace Drupal\Core\Entity Code public function __unset($name) { // Unsetting a field means emptying it. if ($this->hasField($name)) { $this->get($name)->setValue(array()); } // For non-field properties, unset the internal va

PhpBackend::invalidate

public PhpBackend::invalidate($cid) Marks a cache item as invalid. Invalid items may be returned in later calls to get(), if the $allow_invalid argument is TRUE. Parameters string $cid: The cache ID to invalidate. Overrides CacheBackendInterface::invalidate See also \Drupal\Core\Cache\CacheBackendInterface::delete() \Drupal\Core\Cache\CacheBackendInterface::invalidateMultiple() \Drupal\Core\Cache\CacheBackendInterface::invalidateAll() File core/lib/Drupal/Core/Cache/PhpBackend.php, line 184

ContentEntityBase::isDefaultTranslation

public ContentEntityBase::isDefaultTranslation() Checks whether the translation is the default one. Return value bool TRUE if the translation is the default one, FALSE otherwise. Overrides TranslatableInterface::isDefaultTranslation File core/lib/Drupal/Core/Entity/ContentEntityBase.php, line 324 Class ContentEntityBase Implements Entity Field API specific enhancements to the Entity class. Namespace Drupal\Core\Entity Code public function isDefaultTranslation() { return $this->ac

SearchPageListBuilder::__construct

public SearchPageListBuilder::__construct(EntityTypeInterface $entity_type, EntityStorageInterface $storage, SearchPluginManager $search_manager, ConfigFactoryInterface $config_factory) Constructs a new SearchPageListBuilder object. Parameters \Drupal\Core\Entity\EntityTypeInterface $entity_type: The entity type definition. \Drupal\Core\Entity\EntityStorageInterface $storage: The entity storage class. \Drupal\search\SearchPluginManager $search_manager: The search plugin manager. \Drupal\Core\C

Drupal::typedDataManager

public static Drupal::typedDataManager() Returns the typed data manager service. Use the typed data manager service for creating typed data objects. Return value \Drupal\Core\TypedData\TypedDataManagerInterface The typed data manager. See also \Drupal\Core\TypedData\TypedDataManager::create() File core/lib/Drupal.php, line 484 Contains \Drupal. Class Drupal Static Service Container wrapper. Code public static function typedDataManager() { return static::getContainer()->get('typed_d

PoDatabaseReader::setHeader

public PoDatabaseReader::setHeader(PoHeader $header) Implements Drupal\Component\Gettext\PoMetadataInterface::setHeader(). Throws Exception Always, because you cannot set the PO header of a reader. Overrides PoMetadataInterface::setHeader File core/modules/locale/src/PoDatabaseReader.php, line 97 Class PoDatabaseReader Gettext PO reader working with the locale module database. Namespace Drupal\locale Code public function setHeader(PoHeader $header) { throw new \Exception('You cannot