You are here

public function FilterFormatInterface::getHtmlRestrictions in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/filter/src/FilterFormatInterface.php \Drupal\filter\FilterFormatInterface::getHtmlRestrictions()
  2. 10 core/modules/filter/src/FilterFormatInterface.php \Drupal\filter\FilterFormatInterface::getHtmlRestrictions()

Retrieve all HTML restrictions (tags and attributes) for the text format.

Note that restrictions applied to the "*" tag (the wildcard tag, i.e. all tags) are treated just like any other HTML tag. That means that any restrictions applied to it are not automatically applied to all other tags. It is up to the caller to handle this in whatever way it sees fit; this way no information granularity is lost.

Return value

array|false A structured array as returned by FilterInterface::getHTMLRestrictions(), but with the intersection of all filters in this text format. The restrictions will either forbid or allow a list of tags. In the latter case, it's possible that restrictions on attributes are also stored. FALSE means there are no HTML restrictions.

1 method overrides FilterFormatInterface::getHtmlRestrictions()
FilterFormat::getHtmlRestrictions in core/modules/filter/src/Entity/FilterFormat.php
Retrieve all HTML restrictions (tags and attributes) for the text format.

File

core/modules/filter/src/FilterFormatInterface.php, line 80

Class

FilterFormatInterface
Provides an interface defining a filter format entity.

Namespace

Drupal\filter

Code

public function getHtmlRestrictions();