title: OnClick of calendar icon Calendar is not opening Jquery Datepicker
body: <p>I have used a <strong>Jquery Datepicker</strong> in my project on <code>input=text</code> element. Whenever I click on an input element my calendar is opened. But whenever I click on the <code>icon</code> of the datepicker, my calendar is not getting opened. I am imaging why it is happening like this.</p>
  
  <p>Below is my html</p>
  
  <pre><code>&lt;span class="datepicker"&gt;&lt;input type="text" id="feRouteDate" /&gt;&lt;i class="fa fa-calendar" aria-hidden="true"&gt;&lt;/i&gt;&lt;/span&gt;
  </code></pre>
  
  <p>Also see my jquery for the same</p>
  
  <pre><code>$(function () {
      $("#feRouteDate").datepicker({
          dateFormat: 'dd/mm/yy',
          maxDate: 0
      });
  });
  </code></pre>
  
  <p>So, how should I get the calendar opened on click of its icon. Below is how it looks like when the page is loaded</p>
  
  <p><a href="https://i.stack.imgur.com/G76s0.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/G76s0.png" alt="Calendar Icon"></a></p>