Skip to content

Commit

Permalink
Downgrade mbstring to warning, make usage conditional
Browse files Browse the repository at this point in the history
  • Loading branch information
colemanw committed Oct 17, 2016
1 parent 2828842 commit cac6608
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions CRM/Utils/Check/Component/Env.php
Original file line number Diff line number Diff line change
Expand Up @@ -708,9 +708,9 @@ public function checkMbstring() {
if (!function_exists('mb_substr')) {
$messages[] = new CRM_Utils_Check_Message(
__FUNCTION__,
ts('The required PHP Multibyte String extension is not enabled on your server. Ask your system administrator to install it.'),
ts('The PHP Multibyte String extension is needed for CiviCRM to correctly handle user input among other functionality. Ask your system administrator to install it.'),
ts('Missing mbstring Extension'),
\Psr\Log\LogLevel::ERROR,
\Psr\Log\LogLevel::WARNING,
'fa-server'
);
}
Expand Down
2 changes: 1 addition & 1 deletion templates/CRM/Dashlet/Page/Blog.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
<div class="crm-accordion-wrapper collapsed">
<div class="crm-accordion-header">
<span class="crm-news-feed-item-title">{$article.title}</span>
<span class="crm-news-feed-item-preview"> - {$article.description|strip_tags|ltrim|mb_substr:0:100}</span>
<span class="crm-news-feed-item-preview"> - {if !function_exists('mb_substr')}{$article.description|strip_tags|mb_substr:0:100}{else}{$article.description|strip_tags}{/if}</span>
</div>
<div class="crm-accordion-body">
<div>{$article.description}</div>
Expand Down

0 comments on commit cac6608

Please sign in to comment.