title: Close jQuery Fancybox (manually) with a link
body: <p>So I've tried using all the solutions that is available on the internet, but doesn't seem to work for some reason.</p>
  
  <p>I'm using (or the project, rather) fancybox-1.3.4, and other than the close icon, a link needs to be used to close the pop-up.</p>
  
  <p><a href="https://i.stack.imgur.com/GU3Nv.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/GU3Nv.jpg" alt="enter image description here"></a> </p>
  
  <pre><code>&lt;a id="kpitilepoplink" href="#kpitilepop"&gt;Trigger pop-up&lt;/a&gt;
  
  &lt;div style="display:none;"&gt;
      &lt;div id="kpitilepop" class="newpopupcontainer"&gt;
      Contents
      &lt;a href="#" id="popcloselink" class="blu-btn"&gt;Close&lt;/a&gt;
      &lt;/div&gt;
  &lt;/div&gt;
  
  &lt;script type="text/javascript"&gt;
       $(document).ready(function () {                                    
           $("a#kpitilepoplink").fancybox({
           }); 
       });                                     
  &lt;/script&gt; 
  &lt;script type="text/javascript"&gt;
       $(document).ready(function(){
           $('#popcloselink').click(function(){                                       
           alert();
           $(this).fancybox.close();
           });
       });
  &lt;/script&gt; 
  </code></pre>
  
  <p>The solutions available on the internet is not working, and i'm getting <code>fancybox.close is not a function</code> error in the browser console</p>