Solar_Mime::headerLabel()

static public string Solar_Mime::headerLabel ( string $label )

Sanitizes header labels by removing all characters besides [a-zA-z0-9_-].

Parameters

  • (string) $label: The header label to sanitize.

Returns

  • (string) The sanitized header label.

Description

Sanitizes header labels by removing all characters besides [a-zA-z0-9_-].

Underscores are converted to dashes, and word case is normalized.

Converts "foo \r bar_ baz-dib \n 9" to "Foobar-Baz-Dib9".



Local