aboutsummaryrefslogtreecommitdiff
path: root/engine
diff options
context:
space:
mode:
Diffstat (limited to 'engine')
-rw-r--r--engine/classes/ElggMenuItem.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/engine/classes/ElggMenuItem.php b/engine/classes/ElggMenuItem.php
index 36c21b8b4..cfdc2f5fa 100644
--- a/engine/classes/ElggMenuItem.php
+++ b/engine/classes/ElggMenuItem.php
@@ -394,8 +394,10 @@ class ElggMenuItem {
*/
public function getItemClass() {
// allow people to specify name with underscores and colons
- $name = str_replace('_', '-', $this->getName());
+ $name = strtolower($this->getName());
+ $name = str_replace('_', '-', $name);
$name = str_replace(':', '-', $name);
+ $name = str_replace(' ', '-', $name);
$class = implode(' ', $this->data['itemClass']);
if ($class) {