diff --git a/views/bootstrap/class.Bootstrap.php b/views/bootstrap/class.Bootstrap.php
index d42a25bc6..a5bd72e03 100644
--- a/views/bootstrap/class.Bootstrap.php
+++ b/views/bootstrap/class.Bootstrap.php
@@ -3166,8 +3166,10 @@ $('body').on('click', '[id^=\"table-row-folder\"] td:nth-child(2)', function(ev)
}
if($categories = $document->getCategories()) {
$content .= "
";
- foreach($categories as $category)
- $content .= "".$category->getName()." ";
+ foreach($categories as $category) {
+ $color = substr(md5($category->getName()), 0, 6);
+ $content .= "".$category->getName()." ";
+ }
}
if(!empty($extracontent['bottom_title']))
$content .= $extracontent['bottom_title'];
diff --git a/views/bootstrap4/class.Bootstrap4.php b/views/bootstrap4/class.Bootstrap4.php
index 58fb5b981..a4107fa80 100644
--- a/views/bootstrap4/class.Bootstrap4.php
+++ b/views/bootstrap4/class.Bootstrap4.php
@@ -3244,8 +3244,10 @@ $('body').on('click', '[id^=\"table-row-folder\"] td:nth-child(2)', function(ev)
}
if($categories = $document->getCategories()) {
$content .= "
";
- foreach($categories as $category)
- $content .= "".$category->getName()." ";
+ foreach($categories as $category) {
+ $color = substr(md5($category->getName()), 0, 6);
+ $content .= "".$category->getName()." ";
+ }
}
if(!empty($extracontent['bottom_title']))
$content .= $extracontent['bottom_title'];