Skip to content
Snippets Groups Projects
Commit ebaa3442 authored by Demian Katz's avatar Demian Katz
Browse files

Added Unicode normalization to Clickatell class.

parent d8f18fa1
No related merge requests found
......@@ -67,6 +67,10 @@ class Clickatell extends AbstractBase
if (!function_exists('iconv')) {
throw new MailException('Clickatell requires iconv PHP extension.');
}
// Normalize UTF-8 if intl extension is installed:
if (class_exists('Normalizer')) {
$message = \Normalizer::normalize($message);
}
$message = iconv('UTF-8', 'ISO-8859-1//TRANSLIT', $message);
// We need to trim to 160 bytes (note that we need to use substr and not
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment