 jQuery(document).ready(function () {
      //uses source from online(make sure the file has CORS access enabled if used in cross domain)
      var pdf='<?php echo base_url();?><?php echo $magazine[$i]->filepath; ?>';      
      //var pdf ='https://polymertubing.in/flipbook_sagar/books/PlexConnect-Edition5.pdf';
      var options = {
        height: 1000,
        duration: 700,
        backgroundColor: "#2F2F2F"
      };
      var flipBook = $("#flipbookContainer").flipBook(pdf, options);
    });