MailHandler::$mailManager

Mail manager service. Type: \Drupal\Core\Mail\MailManagerInterface File core/modules/contact/src/MailHandler.php, line 39 Class MailHandler Provides a class for handling assembly and dispatch of contact mail messages. Namespace Drupal\contact Code protected $mailManager;

MailHandler::$logger

Logger service. Type: \Drupal\Core\Logger\LoggerChannelInterface File core/modules/contact/src/MailHandler.php, line 32 Class MailHandler Provides a class for handling assembly and dispatch of contact mail messages. Namespace Drupal\contact Code protected $logger;

MailHandler::$languageManager

Language manager service. Type: \Drupal\Core\Language\LanguageManagerInterface File core/modules/contact/src/MailHandler.php, line 25 Class MailHandler Provides a class for handling assembly and dispatch of contact mail messages. Namespace Drupal\contact Code protected $languageManager;

MailHandler

Provides a class for handling assembly and dispatch of contact mail messages. Hierarchy class \Drupal\contact\MailHandler implements MailHandlerInterface uses StringTranslationTrait File core/modules/contact/src/MailHandler.php, line 16 Namespace Drupal\contact Members Name Modifiers Type Description MailHandler::$languageManager protected property Language manager service. MailHandler::$logger protected property Logger service. MailHandler::$mailManager prot

MailFormatHelper::wrapMailLine

protected static MailFormatHelper::wrapMailLine(&$line, $key, $values) Wraps words on a single line. Callback for array_walk() within \Drupal\Core\Mail\MailFormatHelper::wrapMail(). Note that we are skipping MIME content header lines, because attached files, especially applications, could have long MIME types or long filenames which result in line length longer than the 77 characters limit and wrapping that line will break the email format. For instance, the attached file hello_drupal.docx

MailFormatHelper::wrapMail

public static MailFormatHelper::wrapMail($text, $indent = '') Performs format=flowed soft wrapping for mail (RFC 3676). We use delsp=yes wrapping, but only break non-spaced languages when absolutely necessary to avoid compatibility issues. We deliberately use LF rather than CRLF, see MailManagerInterface::mail(). Parameters string $text: The plain text to process. string $indent: (optional) A string to indent the text with. Only '>' characters are repeated on subsequent wrapped lines. Other

MailFormatHelper::htmlToTextPad

protected static MailFormatHelper::htmlToTextPad($text, $pad, $prefix = '') Pads the last line with the given character. Parameters string $text: The text to pad. string $pad: The character to pad the end of the string with. string $prefix: (optional) Prefix to add to the string. Return value string The padded string. See also \Drupal\Core\Mail\MailFormatHelper::htmlToText() File core/lib/Drupal/Core/Mail/MailFormatHelper.php, line 380 Class MailFormatHelper Defines a class containing u

MailFormatHelper::htmlToTextClean

protected static MailFormatHelper::htmlToTextClean($indent) Replaces non-quotation markers from a piece of indentation with spaces. Callback for array_map() within \Drupal\Core\Mail\MailFormatHelper::htmlToText(). File core/lib/Drupal/Core/Mail/MailFormatHelper.php, line 361 Class MailFormatHelper Defines a class containing utility methods for formatting mail messages. Namespace Drupal\Core\Mail Code protected static function htmlToTextClean($indent) { return preg_replace('/[^>]/'

MailFormatHelper::htmlToText

public static MailFormatHelper::htmlToText($string, $allowed_tags = NULL) Transforms an HTML string into plain text, preserving its structure. The output will be suitable for use as 'format=flowed; delsp=yes' text (RFC 3676) and can be passed directly to MailManagerInterface::mail() for sending. We deliberately use LF rather than CRLF, see MailManagerInterface::mail(). This function provides suitable alternatives for the following tags: <a> <em> <i> <strong> <b> &l

MailFormatHelper::htmlToMailUrls

protected static MailFormatHelper::htmlToMailUrls($match = NULL, $reset = FALSE) Keeps track of URLs and replaces them with placeholder tokens. Callback for preg_replace_callback() within \Drupal\Core\Mail\MailFormatHelper::htmlToText(). File core/lib/Drupal/Core/Mail/MailFormatHelper.php, line 333 Class MailFormatHelper Defines a class containing utility methods for formatting mail messages. Namespace Drupal\Core\Mail Code protected static function htmlToMailUrls($match = NULL, $reset