I have the following code that should add an active css class to the menu item if menu item url == current url:
$(\"#accordion a\").each(function() {
$('#accordion a[href="'+ window.location.hostname +'"]').addClass('active-sidebar-link');