From 213dedd780ef4172d49a73ae24251304a4799ae2 Mon Sep 17 00:00:00 2001 From: Joel Mellon Date: Sat, 15 Aug 2020 10:56:02 -0700 Subject: [PATCH] Update sidebar.blade.php Use smarter logic to determine if menu item is active --- src/resources/views/base/inc/sidebar.blade.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/resources/views/base/inc/sidebar.blade.php b/src/resources/views/base/inc/sidebar.blade.php index 60ece0a68e..5daf0653a2 100644 --- a/src/resources/views/base/inc/sidebar.blade.php +++ b/src/resources/views/base/inc/sidebar.blade.php @@ -58,11 +58,11 @@ function() { return $(this).attr('href') === full_url; } // If not found, look for the link that starts with the url if(!$curentPageLink.length > 0){ $curentPageLink = $navLinks.filter( function() { - if ($(this).attr('href').startsWith(full_url)) { + if ($(this).attr('href').split('?')[0] === full_url) { return true; } - if (full_url.startsWith($(this).attr('href'))) { + if (full_url.split('?')[0] === $(this).attr('href')) { return true; }