title: Click on an element triggers the click on another element [JQuery]
body: <p>I have a top menu with the buttons <code>home</code>, <code>prodotti</code>, <code>info</code> and <code>contatti</code>. Below there is an accordion menu that has always an open slide and when you click on a title it changes and opens the relative slide.</p>
  
  <p><img src="https://i.stack.imgur.com/88V3M.png" alt="screenshot"></p>
  
  <p>I would like that when I press for example on <code>contatti</code> in the top menu it triggers the click on <code>contattaci</code> in the accordion menu so that the relative slide opens as if i clicked directly on <code>contattaci</code> (using JQuery).</p>
  
  <p><img src="https://i.stack.imgur.com/q5Cy2.png" alt="screenshot2"></p>
  
  <p>The HTML of the top menu looks like this:</p>
  
  <pre><code>&lt;div id='cssmenu'&gt;
                      &lt;ul&gt;
                          &lt;li id="home" class='active'&gt;&lt;span&gt;Home&lt;/span&gt;&lt;/li&gt;
  
                          &lt;li id="prodotti"&gt;&lt;span&gt;Prodotti&lt;/span&gt;&lt;/li&gt;
  
                          &lt;li id="info"&gt;&lt;span&gt;Info&lt;/span&gt;&lt;/li&gt;
  
                          &lt;li id="contact" class='last'&gt;&lt;span&gt;Contatti&lt;/span&gt;&lt;/li&gt;
                      &lt;/ul&gt;
                  &lt;/div&gt;
  </code></pre>
  
  <p>The HTML of the accordion menu looks like this:</p>
  
  <pre><code>&lt;div class="container"&gt;
  &lt;div id="demo"&gt;
  &lt;ol&gt;
  ...................
  &lt;li id="contattaci"&gt;
  &lt;h2&gt;&lt;span&gt;Contattaci&lt;/span&gt;&lt;/h2&gt;
  &lt;div&gt;
  &lt;iframe src="form.php"width="625px" height="400px" &gt;&lt;/iframe&gt;
  &lt;/div&gt;
  &lt;p class="ap-caption"&gt;e-mail&lt;/p&gt;
  &lt;/li&gt;
  ......
  &lt;/ol&gt;
  &lt;/div&gt;
  &lt;div&gt;
  </code></pre>
  
  <p>So when I click on the <code>contatti</code> item of the top menu (with id="<code>contact</code>") I would like to simulate a click on "<code>contattaci</code>" in the accordion menu (with id="<code>contattaci</code>") so that a slide with a contact form opens next to "<code>contattaci</code>".</p>
  
  <p>I'm not sure that it is possible, anyway I tried using this JQuery code:</p>
  
  <pre><code>&lt;script&gt;
      $(document).on('click', '#contact', function() {
          $("#contattaci").click();
      });
  &lt;/script&gt;
  </code></pre>
  
  <p>This doesn't work. I hope you can help me to fix the problem.</p>
  
  <p><strong>EDIT</strong>: The css accordion menu uses css3 but also a jquery library called jquery.accordionpro.min.js that makes use of JQuery Swipe library (<a href="https://github.com/jgarber623/jquery-swipe" rel="noreferrer">https://github.com/jgarber623/jquery-swipe</a>). Probably the slide can be opened using a function in Jquery Swipe library. What do you think? If you can help let me know.</p>
  
  <p><strong>Link</strong> to the website for further analysis: <a href="http://tinyurl.com/m2u5t7d" rel="noreferrer">http://tinyurl.com/m2u5t7d</a></p>