How to get child pages and add unique class only to active page?

I made this by jQuery:

$('.sidebar-list li a').filter(function(){
  return this.href === location.href;
}).addClass('active');

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)