title: add class to parent li when submenu selected
body: <p>i know this question is been so much in this forum, but i am having a problem here despite googling for hours. I want when i selected /click submenu the parent <code>li</code> get class <code>.actives</code> using Javascript/Jquery. Thanks for your help :)
  Here is my code:</p>
  
  <pre><code>        &lt;nav class="navbar navbar-default navbar-static-top"&gt;
      &lt;div class="container-fluid container"&gt;
          &lt;div class="row m04m"&gt;
              &lt;div class="navbar-header"&gt;
                  &lt;button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#main_nav"&gt;
                      &lt;span class="bars"&gt;
                          &lt;span class="icon-bar"&gt;&lt;/span&gt;
                          &lt;span class="icon-bar"&gt;&lt;/span&gt;
                          &lt;span class="icon-bar"&gt;&lt;/span&gt;
                      &lt;/span&gt;
                      &lt;span class="btn-text"&gt;Select Page&lt;/span&gt;
                  &lt;/button&gt;
              &lt;/div&gt;
              &lt;div class="collapse navbar-collapse" id="main_nav"&gt;
                  &lt;ul class="nav navbar-nav"&gt;
                      &lt;li class="active"&gt;&lt;a href="index-2.html"&gt;Home&lt;/a&gt;&lt;/li&gt;
                      &lt;li class=" dropdown"&gt;
                          &lt;a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false"&gt;ABOUT&lt;/a&gt;
                          &lt;ul class="dropdown-menu" role="menu"&gt;
                              &lt;li&gt;&lt;a href="about-us.html"&gt;About Company&lt;/a&gt;&lt;/li&gt;
                              &lt;li&gt;&lt;a href="about-plasma.html"&gt;About Jump&lt;/a&gt;&lt;/li&gt;
                          &lt;/ul&gt;
                      &lt;/li&gt;
                      &lt;li&gt;&lt;a href="services.html"&gt;LINK&lt;/a&gt;&lt;/li&gt;
                  &lt;/ul&gt;
              &lt;/div&gt;
          &lt;/div&gt;
      &lt;/div&gt;
  &lt;/nav&gt; &lt;!--Main Nav--&gt;
  </code></pre>
  
  <p>and here is my css</p>
  
  <pre><code>.actives{background-color:#174069;}
  </code></pre>
  
  <p>Thanks for your help</p>