You are here

public function WordfilterProcessInterface::filterWords in Wordfilter 8.2

Provides filtering of words by the given Wordfilter configuration.

Parameters

string $text: The text to filter.

\Drupal\wordfilter\Entity\WordfilterConfigurationInterface $wordfilter_config: The Wordfilter configuration to use during the filtering process.

string $langcode: (Optional) The language code.

Return value

string The filtered text.

2 methods override WordfilterProcessInterface::filterWords()
DefaultWordfilterProcess::filterWords in src/Plugin/WordfilterProcess/DefaultWordfilterProcess.php
Provides filtering of words by the given Wordfilter configuration.
TokenWordfilterProcess::filterWords in src/Plugin/WordfilterProcess/TokenWordfilterProcess.php
Provides filtering of words by the given Wordfilter configuration.

File

src/Plugin/WordfilterProcessInterface.php, line 28

Class

WordfilterProcessInterface
Defines an interface for Wordfilter Process plugins.

Namespace

Drupal\wordfilter\Plugin

Code

public function filterWords($text, WordfilterConfigurationInterface $wordfilter_config, $langcode = LanguageInterface::LANGCODE_NOT_SPECIFIED);