title: MagnificPopup with ajax displays loaded content above the page instead of opening it in a modal
body: <p>Instead opening loaded content in a modal, magnific popup simply prepend it in the page's body. The console did not log any errors.</p>
  
  <p>Here's the pseudo code:</p>
  
  <p><strong>CALLER FILE(It's in the exactly same order of the real one):</strong></p>
  
  <pre><code>&lt;script src="http://code.jquery.com/jquery-latest.min.js"&gt;&lt;/script&gt;
  
  &lt;a class="popup" href="/address/to/file.php"&gt;
  
  &lt;script src="/helpers/magnificpopup/jquery.magnific-popup.min.js"&gt;&lt;/script&gt;
  &lt;link href="/helpers/magnificpopup/magnific-popup.css"&gt;
  &lt;script&gt;
  jQuery(document).ready(function ( ) {
      jQuery('.popup').magnificPopup({
          type: 'ajax',
          alignTop: true,
          overflowY: 'scroll',
          closeOnBgClick: false
      });
  }
  &lt;/script&gt;    
  </code></pre>
  
  <p><strong>File.php's INNER HTML:</strong></p>
  
  <pre><code>&lt;div class="white-popup-block"&gt;
      &lt;h1&gt;Hello World!&lt;/h1&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p><strong>The result is this:</strong>
  <a href="https://i.stack.imgur.com/YzQKU.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/YzQKU.png" alt="enter image description here"></a></p>
  
  <p><strong>Instead of(this one is an edition):</strong>
  <a href="https://i.stack.imgur.com/K4RVT.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/K4RVT.png" alt="enter image description here"></a></p>
  
  <p>I already tried to change the magnificpopup version, using one that works well on another application. In this attempt, i used the same JS file and a copy/paste the code from the application where it works. But the result remains the same.</p>
  
  <p>Any ideas, folks?!</p>
  
  <p>Thx</p>