title: Jquery addClass is not persistent
body: <p>I have a web application that I'm developing in Django. I wnat to have a simple way to track where the user is on the site.
  So I thought I would change the css of the item clicked on the menu.</p>
  
  <p>I added this simple piece of code.</p>
  
  <pre><code> &lt;script type="text/javascript"&gt;
          $(document).ready(function(){
  
          $(".up_menu_item").click(function(){
                  $(this).addClass("green");
                  var excludeThis = $(this);
                  $(".up_menu_item").not(excludeThis).each(function(){
                          $(this).removeClass("green");
                  });
          });
  
          });
          &lt;/script&gt;
  </code></pre>
  
  <p>When I click on the menu item, the color changes, but it turns back to default right after. The item I click on are actually  tags which redirect the user to another url. But the menu (and the javascript) is always included in the urls called, so I thought the class would stay.</p>
  
  <p>I don't know if I'm very clear, but I would appreciate any help as this is starting to drive me crazy!</p>