$(document).ready( function() {
  $(".category a").each( function() {
    var url = document.URL.split("#");

    if ( this == url[0] || this + "index.php" == url[0]) {
      $(this).parent().addClass("current");
    }
  });
});
