function FilterFormatInterface::getHtmlRestrictions
Same name in other branches
- 8.9.x core/modules/filter/src/FilterFormatInterface.php \Drupal\filter\FilterFormatInterface::getHtmlRestrictions()
- 10 core/modules/filter/src/FilterFormatInterface.php \Drupal\filter\FilterFormatInterface::getHtmlRestrictions()
- 11.x 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\filterCode
public function getHtmlRestrictions();
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.