title: How to make list-menu display when it have class active?
body: <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>jQuery(document).ready(function() {
    $(".list-menu").hide();
    $(".head-list a").click(function() {
      $(".list-menu:visible").slideUp('slow');
      $(".head-list").removeClass('active-menu');
      $(this).parent().addClass('active-menu').next().slideDown('slow');
      return false;
    });
    if ($(".list-menu ul li").hasClass('active')) {
      $(".list-menu").show();
    }
  });</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"&gt;&lt;/script&gt;
  &lt;div class="head-list"&gt;&lt;a href=""&gt;Puchase&lt;/a&gt;&lt;/div&gt;
  &lt;div class="list-menu"&gt;
    &lt;ul&gt;
      &lt;li class="&lt;?php if($page == 'home'){ echo 'active';} ?&gt;"&gt;&lt;a href="customer_list.php"&gt;Purchase&lt;/a&gt;&lt;/li&gt;
      &lt;li&gt;&lt;a href="#"&gt;Purchase List&lt;/a&gt;&lt;/li&gt;
      &lt;li&gt;&lt;a href="#"&gt;Purchase3&lt;/a&gt;&lt;/li&gt;
      &lt;li&gt;&lt;a href="#"&gt;Purchase4&lt;/a&gt;&lt;/li&gt;
      &lt;li&gt;&lt;a href="#"&gt;Purchase5&lt;/a&gt;&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>I Wanna it to display the <code>.list-menu</code> that have <code>ul li</code> class <code>active</code> only.</p>
  
  <p>Thank You for your answers.</p>