fix multi-byte string processing

This commit is contained in:
yggverse 2024-04-14 14:51:12 +03:00
parent 9bea4fe4a1
commit 7ac9260ba7
2 changed files with 4 additions and 4 deletions

View File

@ -158,8 +158,8 @@ class App
if ($value)
{
$title = urldecode(
strlen($value) > $this->config->header->title->length->max ? substr($value, 0, $this->config->header->title->length->max) . '...'
: $value
mb_strlen($value) > $this->config->header->title->length->max ? mb_substr($value, 0, $this->config->header->title->length->max) . '...'
: $value
);
}

View File

@ -640,8 +640,8 @@ class Page
if ($value)
{
$title = urldecode(
strlen($value) > $this->config->title->length->max ? substr($value, 0, $this->config->title->length->max) . '...'
: $value
mb_strlen($value) > $this->config->title->length->max ? mb_substr($value, 0, $this->config->title->length->max) . '...'
: $value
);
}