public static function PHPMailer::hasLineLongerThanMax
Search API
5.x PHPMailer.php | public static PHPMailer::hasLineLongerThanMax($str) |
Detect if a string contains a line longer than the maximum line length allowed by RFC 2822 section 2.1.1.
Parameters
string $str:
Return value
bool
1 call to PHPMailer::hasLineLongerThanMax()
- PHPMailer::createBody in inc/
PHPMailer/ src/ PHPMailer.php - Assemble the message body. Returns an empty string on failure.
File
- inc/
PHPMailer/ src/ PHPMailer.php, line 4525
Class
- PHPMailer
- PHPMailer - PHP email creation and transport class.
Namespace
PHPMailer\PHPMailerCode
public static function hasLineLongerThanMax($str)
{
return (bool) preg_match('/^(.{' . (self::MAX_LINE_LENGTH + strlen(static::$LE)) . ',})/m', $str);
}