/ Published in: JavaScript
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
$('#localNav a').each(function(idx){ var href=window.location.href; if (this.href.toLowerCase() == href.toLowerCase()) { $(this).addClass('active'); return !1; }; });