You could try something like this:

function filterPath(pathString) {
return pathString.replace(/^\//,'').replace(/\/(index\.\w{3,4})? $/,'')
}

$('a').filter(function() {
  return filterPath(this.pathname) == filterPath(location.pathname);
}).addClass('active');


Then, style an active class in your stylesheet.



--Karl

____________
Karl Swedberg
www.englishrules.com
www.learningjquery.com




On Oct 13, 2008, at 7:22 AM, suntrop wrote:


No one can help?

I tought with jquery one can select everything!

Reply via email to