SHARE
TWEET

Untitled

a guest Feb 9th, 2013 16 Never
  1. <ul class="static">
  2.     <li class="static"><a class="static menu-item" href="/SitePages"> </a></li>
  3.     <li>other anchor tags</li>
  4.     <li></li>
  5.  </ul>
  6.        
  7. $('a[href="/SitePages"]').bind('click', function(){
  8.     $(this).closest('li').css({
  9.         backgroundColor: "#000"
  10.     });
  11. });
  12.        
  13. $('a[href="/SitePages"]').click(function(){this.parent.css("background-color", "blue")});
  14.        
  15. $('a[href="/SitePages"]').click(function(){this.closest('li').css("background-color", "blue")});
RAW Paste Data
Top