Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Address.php

Address::FROM_STRING_PATTERN

A regex that matches a structure like 'Name <email@address.com>'. It matches anything between the first < and last > as email address. This allows to use a single string to construct an Address, which can be convenient to use in config, and allows to have more readable config. This does not try to cover all edge cases for address.

File

vendor/symfony/mime/Address.php, line 34

Class

Address
@author Fabien Potencier <fabien@symfony.com>

Namespace

Symfony\Component\Mime

Code

private const FROM_STRING_PATTERN = '~(?<displayName>[^<]*)<(?<addrSpec>.*)>[^>]*~';
RSS feed
Powered by Drupal