Skip to content

Commit 0f11f38

Browse files
authored
[4.0] breadcrumbs html_entities (#32266)
Simple PR for #32265
1 parent 25bc4ab commit 0f11f38

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

modules/mod_breadcrumbs/tmpl/default.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
foreach ($list as $key => $item) :
4949
if ($key !== $last_item_key) :
5050
if (!empty($item->link)) :
51-
$breadcrumbItem = '<a itemprop="item" href="' . Route::_($item->link) . '" class="pathway"><span itemprop="name">' . $item->name . '</span></a>';
51+
$breadcrumbItem = '<a itemprop="item" href="' . Route::_($item->link) . '" class="pathway"><span itemprop="name">' . html_entity_decode($item->name, ENT_QUOTES, 'UTF-8') . '</span></a>';
5252
else :
5353
$breadcrumbItem = '<span itemprop="name">' . $item->name . '</span>';
5454
endif;
@@ -57,7 +57,7 @@
5757
<meta itemprop="position" content="<?php echo $key + 1; ?>">
5858
</li>
5959
<?php elseif ($show_last) :
60-
$breadcrumbItem = '<span itemprop="name">' . $item->name . '</span>';
60+
$breadcrumbItem = '<span itemprop="name">' . html_entity_decode($item->name, ENT_QUOTES, 'UTF-8') . '</span>';
6161
// Render last item if required. ?>
6262
<li aria-current="page" itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem" class="mod-breadcrumbs__item breadcrumb-item active"><?php echo $breadcrumbItem; ?>
6363
<meta itemprop="position" content="<?php echo $key + 1; ?>">

0 commit comments

Comments
 (0)